Interface RewriteMap
- 
- All Known Implementing Classes:
- InternalRewriteMap.Escape,- InternalRewriteMap.LowerCase,- InternalRewriteMap.Unescape,- InternalRewriteMap.UpperCase,- RandomizedTextRewriteMap
 
 public interface RewriteMapInterface for user defined lookup/replacement logic that can be defined in arewrite.configfile by aRewriteMapdirective. Such a map can then be used by aRewriteRuledefined in the same file.An example rewrite.configfile could look like:RewriteMap uc example.UpperCaseMap RewriteRule ^/(.*)$ ${uc:$1}One parameter can be optionally appended to theRewriteMapdirective. This could be used – for example – to specify a name of a file, that contains a lookup table used by the implementation of the map.
- 
- 
Method SummaryAll Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description java.lang.Stringlookup(java.lang.String key)Maps a key to a replacement value.
 The method is free to returnnullto indicate, that the default value from theRewriteRuledirective should be used.java.lang.StringsetParameters(java.lang.String params)Optional parameter that can be defined through theRewriteMapdirective in therewrite.configfile.default voidsetParameters(java.lang.String... params)Optional parameters that can be defined through theRewriteMapdirective in therewrite.configfile.
 
- 
- 
- 
Method Detail- 
setParametersjava.lang.String setParameters(java.lang.String params) Optional parameter that can be defined through theRewriteMapdirective in therewrite.configfile.- Parameters:
- params- the optional parameter
- Returns:
- value is currently ignored
 
 - 
setParametersdefault void setParameters(java.lang.String... params) Optional parameters that can be defined through theRewriteMapdirective in therewrite.configfile.This method will be called, if there are more than one parameters defined. - Parameters:
- params- the optional parameters
 
 - 
lookupjava.lang.String lookup(java.lang.String key) Maps a key to a replacement value.
 The method is free to returnnullto indicate, that the default value from theRewriteRuledirective should be used.- Parameters:
- key- used by the actual implementation to generate a mapped value
- Returns:
- mapped value or null
 
 
- 
 
-