com.aspose.html.window

Class Location



  • @DOMObjectAttribute
     @DOMNameAttribute(name="Location")
    public class Location
    extends Url

    Location objects provide a representation of the address of the active document of their Document's browsing context, and allow the current entry of the browsing context's session history to be changed, by adding or replacing entries in the history object.

    • Constructor Detail

      • Location

        public Location(Url url)

        Initializes a new instance of the Location class.

        Parameters:
        url - The URL.
    • Method Detail

      • assign

        @DOMNameAttribute(name="assign")
        public void assign(String url)

        Navigates to the given page.

        Parameters:
        url - The URL to navigate.
      • replace

        @DOMNameAttribute(name="replace")
        public void replace(String url)

        Removes the current page from the session history and navigates to the given page.

        Parameters:
        url - The URL to navigate.