public class QoSRule
extends java.lang.Object
| Constructor and Description |
|---|
QoSRule(java.util.regex.Pattern urlPattern)
Creates a new QoS rule object with the
given pattern.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addAction(java.lang.String action)
Adds an action.
|
void |
clearAction()
Removes all actions for this rule.
|
java.util.List<java.lang.String> |
getActions()
Returns a list of actions which hase to be performed.
|
java.lang.Double |
getReject()
Returns the ratio which indicates
if the request should be rejected
or not.
|
java.util.regex.Pattern |
getUrlPattern()
Returns a precompiled pattern
for this rule.
|
java.lang.Double |
getWarn()
Returns the ratio which indicates
if the request should be logged
with a warning or not.
|
boolean |
performAction()
Indicates if an action has to be performed or not.
|
void |
removeAction(java.lang.String action)
Removes the action.
|
void |
setReject(java.lang.Double reject)
Sets the ratio which indicates
if the request should be rejected
or not.
|
void |
setWarn(java.lang.Double warn)
Returns the ratio which indicates
if the request should be logged
with a warning or not.
|
public QoSRule(java.util.regex.Pattern urlPattern)
urlPattern - the url pattern for this rulepublic java.lang.Double getReject()
public void setReject(java.lang.Double reject)
reject - the ratiopublic java.lang.Double getWarn()
public void setWarn(java.lang.Double warn)
warn - the ratiopublic java.util.regex.Pattern getUrlPattern()
public boolean performAction()
public java.util.List<java.lang.String> getActions()
public void addAction(java.lang.String action)
action - the actionpublic void removeAction(java.lang.String action)
action - the actionpublic void clearAction()