public class XBMCExpression
extends java.lang.Object
Constructor and Description |
---|
XBMCExpression()
Default constructor
|
Modifier and Type | Method and Description |
---|---|
boolean |
getClear()
Used to find out if the dest field should be cleared when a expression fails
|
boolean |
getFixChars(int field)
Used to find out if the field should be fixed
|
boolean |
getNoClean(int field)
Used to find out if a field should not be cleaned
|
java.util.regex.Pattern |
getPattern()
Used to get the pattern as a have REGEXP pattern
|
boolean |
getRepeat()
Used to work out if the expression should match until it does not match
|
boolean |
getTrim(int field)
Used to find out if a field should be trimmed.
|
boolean |
isCaseSenstive()
Used to find out if the regexp is case sensitive
|
boolean |
isEmpty()
Used to find out if this is a empty expression
|
void |
parse(java.lang.String regexp,
org.w3c.dom.Element expNode)
Used to parse the regexp expression from the XML node
|
void |
setCaseSenstive(boolean caseSenstive)
Used to set if the regexp is case sensitive
|
void |
setClear(boolean clear)
If set to true, then if the expression fails the dest field is clear
|
void |
setEmpty(boolean empty)
Used to set this as a empty expression
|
void |
setFixChars(java.lang.String value)
Fix characters in fields
|
void |
setNoClean(java.lang.String value)
By default HTML tags and special characters are stripped from the
matches.
|
void |
setPattern(java.util.regex.Pattern pattern)
Used to set the REGEXP pattern of the expression
|
void |
setRepeat(boolean repeat)
Used to set if the expression should match until it does not match
|
void |
setTrim(java.lang.String value)
trim white spaces from the end of matches
|
java.lang.String |
toString() |
public java.util.regex.Pattern getPattern()
public void setPattern(java.util.regex.Pattern pattern)
pattern
- the REGEXP pattern of the expressionpublic boolean getNoClean(int field)
field
- The field to checkpublic boolean getTrim(int field)
field
- The field to checkpublic boolean getFixChars(int field)
field
- The field to checkpublic boolean getClear()
public void setClear(boolean clear)
clear
- If set to true, then if the expression fails the dest field is clearpublic void setNoClean(java.lang.String value)
value
- A comma separated list of field numbers that should not be cleanedpublic void setTrim(java.lang.String value)
value
- A comma separated list of field numbers that should trimmedpublic void setFixChars(java.lang.String value)
value
- A comma separated list of field numbers that should fixedpublic boolean getRepeat()
public void setRepeat(boolean repeat)
repeat
- True to keep matchingpublic java.lang.String toString()
toString
in class java.lang.Object
public boolean isEmpty()
public void setEmpty(boolean empty)
empty
- True if this is a empty expressionpublic boolean isCaseSenstive()
public void setCaseSenstive(boolean caseSenstive)
caseSenstive
- True if the rexexp is case sensitivepublic void parse(java.lang.String regexp, org.w3c.dom.Element expNode)
regexp
- The expressionexpNode
- The node