java.lang.Object
org.eclipse.jetty.rewrite.handler.Rule
org.eclipse.jetty.rewrite.handler.PatternRule
- Direct Known Subclasses:
CookiePatternRule,HeaderPatternRule,RedirectPatternRule,ResponsePatternRule,RewritePatternRule,TerminatingPatternRule
Abstract rule that uses the Servlet pattern syntax via
ServletPathSpec for path pattern matching.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.eclipse.jetty.rewrite.handler.Rule
Rule.Handler, Rule.HttpURIHandler -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract Rule.Handlerapply(Rule.Handler input) Invoked after the Servlet pattern matched the URI path to apply the rule's logic.matchAndApply(Rule.Handler input) Tests whether the givenRequestshould apply, and if so the rule logic is triggered.voidsetPattern(String pattern) toString()Returns the handling and terminating flag values.Methods inherited from class org.eclipse.jetty.rewrite.handler.Rule
isTerminating, setTerminating
-
Constructor Details
-
PatternRule
protected PatternRule() -
PatternRule
-
-
Method Details
-
getPattern
-
setPattern
-
matchAndApply
Description copied from class:RuleTests whether the given
Requestshould apply, and if so the rule logic is triggered.- Specified by:
matchAndApplyin classRule- Parameters:
input- the inputRequestandHandler- Returns:
- the possibly wrapped
RequestandHandler, ornullif the rule did not match - Throws:
IOException- if applying the rule failed
-
apply
Invoked after the Servlet pattern matched the URI path to apply the rule's logic.
- Parameters:
input- the inputRequestandHandler- Returns:
- the possibly wrapped
RequestandHandler - Throws:
IOException- if applying the rule failed
-
toString
Description copied from class:RuleReturns the handling and terminating flag values.
-