| java.lang.Object org.apache.beehive.netui.tags.internal.PageFlowTagUtils
PageFlowTagUtils | public class PageFlowTagUtils (Code) | | This is a utility class for the beehive tags with routines for helping with URL rewriting.
Includes methods to create a fully-rewritten url based on an initial url with query
parameters and an anchor (location on page), checking if it needs to be secure and
rewriting. There's also a method to check if a url is an action.
|
Inner Class :public static class MappingAndController | |
Method Summary | |
public static MappingAndController | getActionMapping(HttpServletRequest request, FlowController flowController, String action) | public static String | getToken(HttpServletRequest request, String action) Get or generate a token used to prevent double submits to an action. | public static String | getToken(HttpServletRequest request, ActionMapping mapping) Get or generate a token used to prevent double submits to an action. | public static boolean | isAction(HttpServletRequest request, String action) Determine whether a given URI is an Action.
Parameters: request - the current HttpServletRequest. Parameters: action - the URI to check. | public static String | rewriteActionURL(PageContext pageContext, String action, Map params, String location) Create a fully-rewritten url from an initial action url with query parameters
and an anchor (location on page), checking if it needs to be secure then call
the rewriter service using a type of
org.apache.beehive.netui.core.urls.URLType.ACTION .
Parameters: pageContext - the current PageContext. Parameters: action - the action url to rewrite. Parameters: params - the query parameters for this url. Parameters: location - the location (anchor or fragment) for this url. | public static String | rewriteHrefURL(PageContext pageContext, String url, Map params, String location) Create a fully-rewritten url from an initial href url with query parameters
and an anchor (location on page), checking if it needs to be secure then call
the rewriter service using a type of
org.apache.beehive.netui.core.urls.URLType.ACTION .
Parameters: pageContext - the current PageContext. Parameters: url - the href url to rewrite. Parameters: params - the query parameters for this url. Parameters: location - the location (anchor or fragment) for this url. | public static String | rewriteResourceURL(PageContext pageContext, String url, Map params, String location) Create a fully-rewritten url from an initial resource url with query parameters
and an anchor (location on page), checking if it needs to be secure then call
the rewriter service using a type of
org.apache.beehive.netui.core.urls.URLType.RESOURCE .
Parameters: pageContext - the current PageContext. Parameters: url - the resource url to rewrite. Parameters: params - the query parameters for this url. Parameters: location - the location (anchor or fragment) for this url. |
getToken | public static String getToken(HttpServletRequest request, String action)(Code) | | Get or generate a token used to prevent double submits to an action. The token is stored in the session,
and checked (and removed) when processing an action with the preventDoubleSubmit attribute
set to true .
|
getToken | public static String getToken(HttpServletRequest request, ActionMapping mapping)(Code) | | Get or generate a token used to prevent double submits to an action. The token is stored in the session,
and checked (and removed) when processing an action with the preventDoubleSubmit attribute
set to true .
|
isAction | public static boolean isAction(HttpServletRequest request, String action)(Code) | | Determine whether a given URI is an Action.
Parameters: request - the current HttpServletRequest. Parameters: action - the URI to check. true if the action is defined in the current page flowor in a shared flow. Otherwise, return false . |
rewriteActionURL | public static String rewriteActionURL(PageContext pageContext, String action, Map params, String location) throws URISyntaxException(Code) | | Create a fully-rewritten url from an initial action url with query parameters
and an anchor (location on page), checking if it needs to be secure then call
the rewriter service using a type of
org.apache.beehive.netui.core.urls.URLType.ACTION .
Parameters: pageContext - the current PageContext. Parameters: action - the action url to rewrite. Parameters: params - the query parameters for this url. Parameters: location - the location (anchor or fragment) for this url. a uri that has been run through the URL rewriter service. |
|
|