Class Substitution.MapElement
- java.lang.Object
-
- org.apache.catalina.valves.rewrite.Substitution.SubstitutionElement
-
- org.apache.catalina.valves.rewrite.Substitution.MapElement
-
- Enclosing class:
- Substitution
public class Substitution.MapElement extends Substitution.SubstitutionElement
Substitution element that performs a rewrite map lookup.
-
-
Field Summary
Fields Modifier and Type Field Description Substitution.SubstitutionElement[]defaultValueThe default value elements if map lookup fails.Substitution.SubstitutionElement[]keyThe key elements for the map lookup.RewriteMapmapThe rewrite map to use for lookup.
-
Constructor Summary
Constructors Constructor Description MapElement()Constructs a new MapElement.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Stringevaluate(java.util.regex.Matcher rule, java.util.regex.Matcher cond, Resolver resolver)Evaluates this element against the given matchers and resolver.
-
-
-
Field Detail
-
map
public RewriteMap map
The rewrite map to use for lookup.
-
defaultValue
public Substitution.SubstitutionElement[] defaultValue
The default value elements if map lookup fails.
-
key
public Substitution.SubstitutionElement[] key
The key elements for the map lookup.
-
-
Method Detail
-
evaluate
public java.lang.String evaluate(java.util.regex.Matcher rule, java.util.regex.Matcher cond, Resolver resolver)Description copied from class:Substitution.SubstitutionElementEvaluates this element against the given matchers and resolver.- Specified by:
evaluatein classSubstitution.SubstitutionElement- Parameters:
rule- the rewrite rule matchercond- the condition matcherresolver- the property resolver- Returns:
- the evaluated string
-
-