Class NavigationCaseWrapper
- All Implemented Interfaces:
FacesWrapper<NavigationCase>
Provides a simple implementation of
NavigationCase that can be subclassed by developers wishing to
provide specialized behavior to an existing NavigationCase
instance. The default implementation of all methods is to call
through to the wrapped NavigationCase instance.
Usage: extend this class and override
getWrapped() to
return the instance being wrapping.
- Since:
- 2.2
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleangetActionURL(FacesContext context) Construct an absolute URL to thisNavigationCaseinstance usingViewHandler.getActionURL(javax.faces.context.FacesContext, java.lang.String)on the path portion of the url.getBookmarkableURL(FacesContext context) Construct an absolute URL suitable for a bookmarkable link to thisNavigationCaseinstance usingViewHandler.getBookmarkableURL(javax.faces.context.FacesContext, java.lang.String, java.util.Map<java.lang.String, java.util.List<java.lang.String>>, boolean)on the path portion of the url.getCondition(FacesContext context) Evaluates the<if>for this<navigation-case>, if any.Return the<from-action> for this<navigation-case>Return the<from-outcome> for this<navigation-case>Return the<from-view-id>of the<navigation-rule>inside which this<navigation-case>is nested.Return the parameters to be included for navigation cases requiring a redirect.getRedirectURL(FacesContext context) Construct an absolute URL suitable for a "redirect" to thisNavigationCaseinstance usingViewHandler.getRedirectURL(javax.faces.context.FacesContext, java.lang.String, java.util.Map<java.lang.String, java.util.List<java.lang.String>>, boolean)on the path portion of the url.getResourceURL(FacesContext context) Construct an absolute URL to thisNavigationCaseinstance usingViewHandler.getResourceURL(javax.faces.context.FacesContext, java.lang.String)on the path portion of the url.If this navigation case represents a flow invocation, this property is the documentId in which the flow whose id is given by the return fromNavigationCase.getFromOutcome()is defined.getToViewId(FacesContext context) Evaluates the<to-view-id>for this<navigation-case>abstract NavigationCaseA class that implements this interface uses this method to return an instance of the class being wrapped.booleanTest if this navigation case has an associated<if>element.inthashCode()booleanReturn the<redirect>value for this<navigation-case>.booleanReturn the<redirect>value for this<navigation-case>.toString()
-
Constructor Details
-
NavigationCaseWrapper
public NavigationCaseWrapper()
-
-
Method Details
-
equals
- Overrides:
equalsin classNavigationCase
-
hashCode
public int hashCode()- Overrides:
hashCodein classNavigationCase
-
toString
- Overrides:
toStringin classNavigationCase
-
getWrapped
Description copied from interface:FacesWrapperA class that implements this interface uses this method to return an instance of the class being wrapped.
- Specified by:
getWrappedin interfaceFacesWrapper<NavigationCase>
-
getActionURL
Description copied from class:NavigationCaseConstruct an absolute URL to this
NavigationCaseinstance usingViewHandler.getActionURL(javax.faces.context.FacesContext, java.lang.String)on the path portion of the url.- Overrides:
getActionURLin classNavigationCase- Parameters:
context- theFacesContextfor the current request- Throws:
MalformedURLException- if the process of constructing the URL causes this exception to be thrown.
-
getBookmarkableURL
Description copied from class:NavigationCaseConstruct an absolute URL suitable for a bookmarkable link to this
NavigationCaseinstance usingViewHandler.getBookmarkableURL(javax.faces.context.FacesContext, java.lang.String, java.util.Map<java.lang.String, java.util.List<java.lang.String>>, boolean)on the path portion of the url. This URL may include view parameters specified as metadata within the view.- Overrides:
getBookmarkableURLin classNavigationCase- Parameters:
context- theFacesContextfor the current request- Throws:
MalformedURLException- if the process of constructing the URL causes this exception to be thrown.
-
getCondition
Description copied from class:NavigationCaseEvaluates the
<if>for this<navigation-case>, if any. The expression to be evaluated is passed into the constructor as a string. When the expression is evaluated, its value must be coerced into abooleanper the normal EL coercion rules.- Overrides:
getConditionin classNavigationCase- Parameters:
context- theFacesContextfor the current request- Returns:
nullif there is no<if>element associated with this<navigation-case>, otherwise return the evaluation result of the condition
-
getFromAction
Description copied from class:NavigationCaseReturn the
<from-action> for this<navigation-case>- Overrides:
getFromActionin classNavigationCase
-
getFromOutcome
Description copied from class:NavigationCaseReturn the
<from-outcome> for this<navigation-case>- Overrides:
getFromOutcomein classNavigationCase
-
getFromViewId
Description copied from class:NavigationCaseReturn the
<from-view-id>of the<navigation-rule>inside which this<navigation-case>is nested.- Overrides:
getFromViewIdin classNavigationCase
-
getParameters
Description copied from class:NavigationCaseReturn the parameters to be included for navigation cases requiring a redirect. If no parameters are defined,
nullwill be returned. The keys in theMapare parameter names. For each key, the corresponding value is aListof unconverted values.- Overrides:
getParametersin classNavigationCase
-
getRedirectURL
Description copied from class:NavigationCaseConstruct an absolute URL suitable for a "redirect" to this
NavigationCaseinstance usingViewHandler.getRedirectURL(javax.faces.context.FacesContext, java.lang.String, java.util.Map<java.lang.String, java.util.List<java.lang.String>>, boolean)on the path portion of the url.- Overrides:
getRedirectURLin classNavigationCase- Parameters:
context- theFacesContextfor the current request- Throws:
MalformedURLException- if the process of constructing the URL causes this exception to be thrown.
-
getResourceURL
Description copied from class:NavigationCaseConstruct an absolute URL to this
NavigationCaseinstance usingViewHandler.getResourceURL(javax.faces.context.FacesContext, java.lang.String)on the path portion of the url.- Overrides:
getResourceURLin classNavigationCase- Parameters:
context- theFacesContextfor the current request- Throws:
MalformedURLException- if the process of constructing the URL causes this exception to be thrown.
-
getToViewId
Description copied from class:NavigationCaseEvaluates the
<to-view-id>for this<navigation-case>- Overrides:
getToViewIdin classNavigationCase- Parameters:
context- theFacesContextfor the current request- Returns:
- the view ID that should be navigated to
-
getToFlowDocumentId
Description copied from class:NavigationCaseIf this navigation case represents a flow invocation, this property is the documentId in which the flow whose id is given by the return from
NavigationCase.getFromOutcome()is defined. Implementations must override this method to return the value defined in the corresponding application configuration resources element. The base implementation returns the empty string.- Overrides:
getToFlowDocumentIdin classNavigationCase
-
hasCondition
public boolean hasCondition()Description copied from class:NavigationCaseTest if this navigation case has an associated
<if>element.- Overrides:
hasConditionin classNavigationCase- Returns:
trueif there's an<if>element associated with this<navigation-case>, otherwisefalse
-
isIncludeViewParams
public boolean isIncludeViewParams()Description copied from class:NavigationCaseReturn the
<redirect>value for this<navigation-case>. This will betrueif the view parametets should be encoded into the redirect URL (only applies to redirect case)- Overrides:
isIncludeViewParamsin classNavigationCase
-
isRedirect
public boolean isRedirect()Description copied from class:NavigationCaseReturn the
<redirect>value for this<navigation-case>. This will betrueif the new view should be navigated to via aExternalContext.redirect(String)- Overrides:
isRedirectin classNavigationCase
-