Skip navigation links


org.apache.myfaces.trinidad.util
Class URLEncoderWrapper

java.lang.Object
  extended by org.apache.myfaces.trinidad.util.URLEncoder
      extended by org.apache.myfaces.trinidad.util.URLEncoderWrapper


public abstract class URLEncoderWrapper
extends URLEncoder

Constructor Summary
URLEncoderWrapper()
           

 

Method Summary
 java.lang.String encodeActionURL(java.lang.String url)
          This function should be the same as the ExternalContext.encodeActionURL(String) method.
 java.lang.String encodeInProtocolResourceURL(java.lang.String url)
          Encodes a url to a resource such that it is inProtocol.
 java.lang.String encodePartialActionURL(java.lang.String url)
          This encodes a URL so that it can be used to make a PPR request in all containers.
 java.lang.String encodeRedirectURL(java.lang.String url)
          Encodes a url to be explicitly used for a redirect.
 java.lang.String encodeResourceURL(java.lang.String url)
          Encodes a url as a resource.
 java.lang.String encodeSkinResourceURL(java.lang.String url)
          Encodes a resource URL that is mapped to a skinning resources.
abstract  URLEncoder getWrapped()
           

 

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Constructor Detail

URLEncoderWrapper

public URLEncoderWrapper()

Method Detail

getWrapped

public abstract URLEncoder getWrapped()

encodeActionURL

public java.lang.String encodeActionURL(java.lang.String url)
Description copied from class: URLEncoder
This function should be the same as the ExternalContext.encodeActionURL(String) method. By default it call the code in the ExternalContext. The reason its provided here is that certain URLEncoderUtility instances may wish to override the default functionality and have the ExternalContext pull its default encoding from here.
Specified by:
encodeActionURL in class URLEncoder

encodeResourceURL

public java.lang.String encodeResourceURL(java.lang.String url)
Description copied from class: URLEncoder
Encodes a url as a resource. Generally speaking this will be equivalent to ExternalContext.encodeResourceURL(String). The url returned from this method is NOT guarenteed to be in-protocol (meaning that it MAY not have access to session information). The advantage of encoding something in this fashion is that in certain types of containers, like portals, the URL generated may have faster access and will generally work better for the purposes of caching do to its RESTful state.
Specified by:
encodeResourceURL in class URLEncoder
Parameters:
url - the unencoded url
Returns:
the encoded url

encodeInProtocolResourceURL

public java.lang.String encodeInProtocolResourceURL(java.lang.String url)
Description copied from class: URLEncoder
Encodes a url to a resource such that it is inProtocol. This means that the URL returned will be encoded in such a way that the resource will have access to the parent application's session. While these URL's do have access to the session information, they may not be written in a format that is easily cachable.
Specified by:
encodeInProtocolResourceURL in class URLEncoder
Parameters:
url - the unencoded url
Returns:
the encoded url

encodePartialActionURL

public java.lang.String encodePartialActionURL(java.lang.String url)
Description copied from class: URLEncoder
This encodes a URL so that it can be used to make a PPR request in all containers. JSF 2.0 has the ability to encode URL's in such a fashion, but this is missing from JSF 1.2 containers. This method provides the same functionality for JSF 1.2.
Specified by:
encodePartialActionURL in class URLEncoder
Parameters:
url - the unencoded url
Returns:
the encoded url

encodeRedirectURL

public java.lang.String encodeRedirectURL(java.lang.String url)
Description copied from class: URLEncoder
Encodes a url to be explicitly used for a redirect. In some containers, this is encoded as-is. In other containers this may not be encoded or must contain a fully qualified url.
Specified by:
encodeRedirectURL in class URLEncoder
Parameters:
url - the unencoded url
Returns:
the encoded url

encodeSkinResourceURL

public java.lang.String encodeSkinResourceURL(java.lang.String url)
Description copied from class: URLEncoder
Encodes a resource URL that is mapped to a skinning resources. Trinidad has an extensive skinning system that allows for extraction of certain properties like images so that they can be used with the componentry. Generally these image resources are on the same server and whatnot as the actual skin. In a servlet environment, this is always the same server, but in portal-like environments these resources may be on different servers. This encodes a URL that comes from a skin and sends it to the right location.
Specified by:
encodeSkinResourceURL in class URLEncoder
Returns:

Skip navigation links


Copyright © 2001-2012 The Apache Software Foundation. All Rights Reserved.