public class JsLocation extends JsElementalMixinBase implements Location
SVG_ZOOMANDPAN_DISABLE, SVG_ZOOMANDPAN_MAGNIFY, SVG_ZOOMANDPAN_UNKNOWN
Modifier | Constructor and Description |
---|---|
protected |
JsLocation() |
Modifier and Type | Method and Description |
---|---|
void |
assign(String url)
Load the document at the provided URL.
|
JsIndexable |
getAncestorOrigins() |
String |
getHash()
the part of the URL that follows the # symbol, including the # symbol.
You can listen for the hashchange event to get notified of changes to the hash in supporting browsers. |
String |
getHost()
the host name and port number.
|
String |
getHostname()
the host name (without the port number or square brackets).
|
String |
getHref()
the entire URL.
|
String |
getOrigin() |
String |
getPathname()
the path (relative to the host).
|
String |
getPort()
the port number of the URL.
|
String |
getProtocol()
the protocol of the URL.
|
String |
getSearch()
the part of the URL that follows the ? symbol, including the ? symbol.
|
void |
reload()
Reload the document from the current URL.
|
void |
replace(String url)
Replace the current document with the one at the provided URL.
|
void |
setHash(String param_hash) |
void |
setHost(String param_host) |
void |
setHostname(String param_hostname) |
void |
setHref(String param_href) |
void |
setPathname(String param_pathname) |
void |
setPort(String param_port) |
void |
setProtocol(String param_protocol) |
void |
setSearch(String param_search) |
addEventListener, addEventListener, beginElement, beginElementAt, dispatchEvent, endElement, endElementAt, getAnimatedClassName, getAnimatedHeight, getAnimatedHref, getAnimatedResult, getAnimatedTransform, getAnimatedWidth, getAnimatedX, getAnimatedY, getBBox, getChildElementCount, getCTM, getExternalResourcesRequired, getFarthestViewportElement, getFirstElementChild, getLastElementChild, getNearestViewportElement, getNextElementSibling, getPresentationAttribute, getPreserveAspectRatio, getPreviousElementSibling, getRequiredExtensions, getRequiredFeatures, getScreenCTM, getSvgStyle, getSystemLanguage, getTransformToElement, getViewBox, getXmllang, getXmlspace, getZoomAndPan, hasExtension, querySelector, querySelectorAll, removeEventListener, removeEventListener, setXmllang, setXmlspace, setZoomAndPan
at, at, intAt, intAt, length, numberAt, numberAt, setAt, setAt, setAt, setAt, setAt, setAt
cast, createArray, createArray, createFunction, createObject, equals, hashCode, toSource, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
intAt, length
numberAt
public final JsIndexable getAncestorOrigins()
getAncestorOrigins
in interface Location
public final String getHash()
Location
public final String getHost()
Location
public final String getHostname()
Location
getHostname
in interface Location
public final void setHostname(String param_hostname)
setHostname
in interface Location
public final String getPathname()
Location
getPathname
in interface Location
public final void setPathname(String param_pathname)
setPathname
in interface Location
public final String getPort()
Location
public final String getProtocol()
Location
getProtocol
in interface Location
public final void setProtocol(String param_protocol)
setProtocol
in interface Location
public final String getSearch()
Location
public final void setSearch(String param_search)
public final void assign(String url)
Location
public final void reload()
Location
forceget
is a boolean, which, when it is true
, causes the page to always be reloaded from the server. If it is false
or not specified, the browser may reload the page from its cache.public final void replace(String url)
Location
assign()
method is that after using replace()
the current page will not be saved in session history, meaning the user won't be able to use the Back button to navigate to it.Copyright © 2016. All rights reserved.