com.liferay.faces.bridge.context.url
Class BridgeURLWrapper

java.lang.Object
  extended by com.liferay.faces.bridge.context.url.BridgeURLWrapper
All Implemented Interfaces:
BridgeURL
Direct Known Subclasses:
BridgeActionURLWrapper, BridgePartialActionURLWrapper, BridgeRedirectURLWrapper, BridgeResourceURLWrapper

public abstract class BridgeURLWrapper
extends Object
implements BridgeURL

Author:
Neil Griffin

Constructor Summary
BridgeURLWrapper()
           
 
Method Summary
 String getContextRelativePath()
          Returns the context-relative path in the URL.
 String getParameter(String name)
          Returns the value of the underlying BridgeURL.getParameterMap() with the specified name.
 Map<String,String[]> getParameterMap()
          Returns a mutable Map representing the URL parameters.
 Set<String> getParameterNames()
          Returns a list of key names from the underlying BridgeURL.getParameterMap().
 Bridge.PortletPhase getPortletPhase()
          Returns the Bridge.PortletPhase associated with this URL.
abstract  BridgeURL getWrapped()
           
 boolean isAbsolute()
          Determines whether or not the URL is absolute.
 boolean isEscaped()
          Determines whether or not the URL is escaped.
 boolean isExternal()
          Determines whether or not the URL is external.
 boolean isFacesViewTarget()
          Determines whether or not the URL targets a Faces View.
 boolean isHierarchical()
          Determines whether or not the URL is hierarchical, meaning it is either 1) absolute and the scheme-specific part begins with a forward-slash character, or 2) is relative.
 boolean isOpaque()
          Determines whether or not the URL is opaque, meaning it is absolute and its scheme component does not begin with a forward-slash character.
 boolean isPathRelative()
          Determines whether or not the path component of the URL is relative, meaning it does not begin with a forward-slash character.
 boolean isPortletScheme()
          Determines whether or not the URL begins with the "portlet:" scheme.
 boolean isSecure()
          Flag indicating whether or not the URL is secure.
 boolean isSelfReferencing()
          Determines whether or not the URL is self-referencing, meaning, it targets the current Faces view.
 String removeParameter(String name)
          Removes the value of the underlying BridgeURL.getParameterMap() with the specified name.
 void setParameter(String name, String value)
          Sets the value of the underlying BridgeURL.getParameterMap() according to the specified name.
 void setParameter(String name, String[] value)
          Sets the value of the underlying BridgeURL.getParameterMap() according to the specified name.
 void setSecure(boolean secure)
          Sets the flag indicating whether or not the URL is secure.
 void setSelfReferencing(boolean selfReferencing)
          Sets the flag indicating whether or not the URL is self-referencing, meaning, whether or not it targets the current Faces view.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.liferay.faces.bridge.context.url.BridgeURL
toString
 

Constructor Detail

BridgeURLWrapper

public BridgeURLWrapper()
Method Detail

removeParameter

public String removeParameter(String name)
Description copied from interface: BridgeURL
Removes the value of the underlying BridgeURL.getParameterMap() with the specified name.

Specified by:
removeParameter in interface BridgeURL

getContextRelativePath

public String getContextRelativePath()
Description copied from interface: BridgeURL
Returns the context-relative path in the URL. If no path is found, then the current Faces viewId (found in the current UIViewRoot) is returned.

Specified by:
getContextRelativePath in interface BridgeURL

isEscaped

public boolean isEscaped()
Description copied from interface: BridgeURL
Determines whether or not the URL is escaped.

Specified by:
isEscaped in interface BridgeURL
Returns:
true if all occurrences of the ampersand character appear as & otherwise, returns false.

isAbsolute

public boolean isAbsolute()
Description copied from interface: BridgeURL
Determines whether or not the URL is absolute.

Specified by:
isAbsolute in interface BridgeURL
Returns:
true if absolute, otherwise false

isOpaque

public boolean isOpaque()
Description copied from interface: BridgeURL
Determines whether or not the URL is opaque, meaning it is absolute and its scheme component does not begin with a forward-slash character. For more information see URI.isOpaque().

Specified by:
isOpaque in interface BridgeURL
Returns:
true if the URL is opaque, otherwise false.

isPathRelative

public boolean isPathRelative()
Description copied from interface: BridgeURL
Determines whether or not the path component of the URL is relative, meaning it does not begin with a forward-slash character.

Specified by:
isPathRelative in interface BridgeURL
Returns:
true if the path is relative, otherwise false.

isPortletScheme

public boolean isPortletScheme()
Description copied from interface: BridgeURL
Determines whether or not the URL begins with the "portlet:" scheme.

Specified by:
isPortletScheme in interface BridgeURL
Returns:
true if the URL begins with the "portlet:" scheme, otherwise false.

isSecure

public boolean isSecure()
Description copied from interface: BridgeURL
Flag indicating whether or not the URL is secure. For more information, see BaseURL.setSecure(boolean).

Specified by:
isSecure in interface BridgeURL
Returns:
true if the URL is secure, otherwise false.

isSelfReferencing

public boolean isSelfReferencing()
Description copied from interface: BridgeURL
Determines whether or not the URL is self-referencing, meaning, it targets the current Faces view.

Specified by:
isSelfReferencing in interface BridgeURL
Returns:
true if self-referencing, otherwise false.

isExternal

public boolean isExternal()
Description copied from interface: BridgeURL
Determines whether or not the URL is external.

Specified by:
isExternal in interface BridgeURL
Returns:
true if external, otherwise false.

isHierarchical

public boolean isHierarchical()
Description copied from interface: BridgeURL
Determines whether or not the URL is hierarchical, meaning it is either 1) absolute and the scheme-specific part begins with a forward-slash character, or 2) is relative.

Specified by:
isHierarchical in interface BridgeURL
Returns:
true if the URL is hierarchical, otherwise false.

getParameter

public String getParameter(String name)
Description copied from interface: BridgeURL
Returns the value of the underlying BridgeURL.getParameterMap() with the specified name.

Specified by:
getParameter in interface BridgeURL

setParameter

public void setParameter(String name,
                         String value)
Description copied from interface: BridgeURL
Sets the value of the underlying BridgeURL.getParameterMap() according to the specified name.

Specified by:
setParameter in interface BridgeURL

setParameter

public void setParameter(String name,
                         String[] value)
Description copied from interface: BridgeURL
Sets the value of the underlying BridgeURL.getParameterMap() according to the specified name.

Specified by:
setParameter in interface BridgeURL

getParameterMap

public Map<String,String[]> getParameterMap()
Description copied from interface: BridgeURL
Returns a mutable Map representing the URL parameters.

Specified by:
getParameterMap in interface BridgeURL

getParameterNames

public Set<String> getParameterNames()
Description copied from interface: BridgeURL
Returns a list of key names from the underlying BridgeURL.getParameterMap().

Specified by:
getParameterNames in interface BridgeURL

getPortletPhase

public Bridge.PortletPhase getPortletPhase()
Description copied from interface: BridgeURL
Returns the Bridge.PortletPhase associated with this URL. Note that the value will be null if the URL does not begin with the "portlet:" scheme/prefix.

Specified by:
getPortletPhase in interface BridgeURL

setSecure

public void setSecure(boolean secure)
Description copied from interface: BridgeURL
Sets the flag indicating whether or not the URL is secure.

Specified by:
setSecure in interface BridgeURL
Parameters:
secure - true if secure, otherwise false.

setSelfReferencing

public void setSelfReferencing(boolean selfReferencing)
Description copied from interface: BridgeURL
Sets the flag indicating whether or not the URL is self-referencing, meaning, whether or not it targets the current Faces view.

Specified by:
setSelfReferencing in interface BridgeURL
Parameters:
selfReferencing - true if self-referencing, otherwise false.

isFacesViewTarget

public boolean isFacesViewTarget()
Description copied from interface: BridgeURL
Determines whether or not the URL targets a Faces View.

Specified by:
isFacesViewTarget in interface BridgeURL
Returns:
true if the URL targets a Faces View, otherwise false

getWrapped

public abstract BridgeURL getWrapped()


Copyright © 2014 Liferay, Inc.. All Rights Reserved.