org.hippoecm.hst.core.container
Interface HstContainerURLProvider

All Known Implementing Classes:
HstContainerURLProviderImpl

public interface HstContainerURLProvider

The URL provider for the HstContainerURL. This is responsible for creating, parsing and stringifying the HstContainerURL.

Version:
$Id: HstContainerURLProvider.java 24942 2010-11-10 15:03:40Z aschrijvers $

Method Summary
 HstContainerURL createURL(HstContainerURL baseContainerURL, HstURL hstUrl)
          Creates an HstContainerURL instance by merging the information of hstUrl based on the base HstContainerURL instance
 HstContainerURL createURL(HstContainerURL baseContainerURL, String pathInfo)
          Creates an HstContainerURL instance for a new pathInfo (without query parameters) based on the base HstContainerURL instance
 HstContainerURL createURL(Mount mount, HstContainerURL baseURL, String path)
          Creates an HstContainerURL instance for a new pathInfo (without query parameters) based on the Mount and the base HstContainerURL instance.
 String getParameterNameComponentSeparator()
          Returns the parameter name component separator.
 void mergeParameters(HstContainerURL containerURL, String referenceNamespace, Map<String,String[]> parameters)
          Merges the render parameters into the containerURL.
 HstContainerURL parseURL(HstRequestContext requestContext, ResolvedMount mount, String requestPath)
          Parses a specified requestPath with the current HstRequestContext for a new ResolvedMount and requestPath and creates an HstContainerURL instance.
 HstContainerURL parseURL(javax.servlet.http.HttpServletRequest servletRequest, javax.servlet.http.HttpServletResponse servletResponse, ResolvedMount resolvedMount)
          Parses the current request and creates an HstContainerURL instance.
 HstContainerURL parseURL(javax.servlet.http.HttpServletRequest request, ResolvedMount mount, String requestPath)
          Parses a request for a specific ResolvedMount and requestPath and creates an HstContainerURL instance.
 void setParameterNameComponentSeparator(String parameterNameComponentSeparator)
          Sets the parameter name component separator.
 String toContextRelativeURLString(HstContainerURL containerURL, HstRequestContext requestContext)
          Stringifying the containerURL as a context relative path.
 String toURLString(HstContainerURL containerURL, HstRequestContext requestContext)
          Stringifying the containerURL as a full URL string.
 String toURLString(HstContainerURL containerURL, HstRequestContext requestContext, String contextPath)
          Stringifying the containerURL as a full URL string.
 

Method Detail

setParameterNameComponentSeparator

void setParameterNameComponentSeparator(String parameterNameComponentSeparator)
Sets the parameter name component separator. If this is set to ':' and the parameter name is 'p1' with value 'v1', then the parameter pair for the HstComponent having the reference namespace 'a' should be 'a:p1=v1'.

Parameters:
parameterNameComponentSeparator -

getParameterNameComponentSeparator

String getParameterNameComponentSeparator()
Returns the parameter name component separator.

Returns:

parseURL

HstContainerURL parseURL(javax.servlet.http.HttpServletRequest servletRequest,
                         javax.servlet.http.HttpServletResponse servletResponse,
                         ResolvedMount resolvedMount)
Parses the current request and creates an HstContainerURL instance.

Parameters:
servletRequest -
servletResponse -
resolvedMount -
Returns:

parseURL

HstContainerURL parseURL(HstRequestContext requestContext,
                         ResolvedMount mount,
                         String requestPath)
Parses a specified requestPath with the current HstRequestContext for a new ResolvedMount and requestPath and creates an HstContainerURL instance.

Parameters:
requestContext -
mount -
requestPath -
Returns:

parseURL

HstContainerURL parseURL(javax.servlet.http.HttpServletRequest request,
                         ResolvedMount mount,
                         String requestPath)
Parses a request for a specific ResolvedMount and requestPath and creates an HstContainerURL instance.

Parameters:
request -
requestPath -
mount -
Returns:

createURL

HstContainerURL createURL(HstContainerURL baseContainerURL,
                          String pathInfo)
Creates an HstContainerURL instance for a new pathInfo (without query parameters) based on the base HstContainerURL instance

Parameters:
baseContainerURL -
pathInfo -
Returns:

createURL

HstContainerURL createURL(Mount mount,
                          HstContainerURL baseURL,
                          String path)
Creates an HstContainerURL instance for a new pathInfo (without query parameters) based on the Mount and the base HstContainerURL instance.

Parameters:
mount -
baseURL -
path -
Returns:

createURL

HstContainerURL createURL(HstContainerURL baseContainerURL,
                          HstURL hstUrl)
Creates an HstContainerURL instance by merging the information of hstUrl based on the base HstContainerURL instance

Parameters:
baseContainerURL -
hstUrl -
Returns:

mergeParameters

void mergeParameters(HstContainerURL containerURL,
                     String referenceNamespace,
                     Map<String,String[]> parameters)
Merges the render parameters into the containerURL.

Parameters:
containerURL -
referenceNamespace -
parameters -

toContextRelativeURLString

String toContextRelativeURLString(HstContainerURL containerURL,
                                  HstRequestContext requestContext)
                                  throws UnsupportedEncodingException,
                                         ContainerException
Stringifying the containerURL as a context relative path.

Parameters:
containerURL -
requestContext -
Returns:
Throws:
UnsupportedEncodingException
ContainerException

toURLString

String toURLString(HstContainerURL containerURL,
                   HstRequestContext requestContext)
                   throws UnsupportedEncodingException,
                          ContainerException
Stringifying the containerURL as a full URL string.

Parameters:
containerURL -
requestContext -
Returns:
Throws:
UnsupportedEncodingException
ContainerException

toURLString

String toURLString(HstContainerURL containerURL,
                   HstRequestContext requestContext,
                   String contextPath)
                   throws UnsupportedEncodingException,
                          ContainerException
Stringifying the containerURL as a full URL string.

By this method, you can specify the context path such as '/mycontext'.

Parameters:
containerURL -
requestContext -
contextPath -
Returns:
Throws:
UnsupportedEncodingException
ContainerException


Copyright © 2008-2012 Hippo. All Rights Reserved.