Class Resource
java.lang.Object
org.ocpsoft.rewrite.config.DefaultConditionBuilder
org.ocpsoft.rewrite.servlet.config.HttpCondition
org.ocpsoft.rewrite.servlet.config.Resource
- All Implemented Interfaces:
Condition,ConditionBuilder,Parameterized
A
Condition responsible for determining existence of resources within the
ServletContext.getResourcePaths(String) of the servlet container.- Author:
- Lincoln Baxter, III
-
Method Summary
Modifier and TypeMethodDescriptionbooleanevaluateHttp(HttpServletRewrite event, EvaluationContext context) static ResourceCreate aConditionthat returnstrueif the given resource exists in theServletContext.getResourcePaths(String)of the current application.Get theParameterizedPatternof thisResource.voidsetParameterStore(ParameterStore store) Methods inherited from class org.ocpsoft.rewrite.servlet.config.HttpCondition
evaluateMethods inherited from class org.ocpsoft.rewrite.config.DefaultConditionBuilder
and, andNot, or, orNot
-
Method Details
-
evaluateHttp
- Specified by:
evaluateHttpin classHttpCondition
-
exists
Create aConditionthat returnstrueif the given resource exists in theServletContext.getResourcePaths(String)of the current application.The given resource path may be parameterized:
/example/{param}.html
/css/{value}.css
...- Parameters:
location-ParameterizedPatternspecifying theAddressof the internal resource.
-
getExpression
Get theParameterizedPatternof thisResource. -
getRequiredParameterNames
- Specified by:
getRequiredParameterNamesin interfaceParameterized
-
setParameterStore
- Specified by:
setParameterStorein interfaceParameterized
-