com.raritantechnologies.xml.sax.filter.comparators
Class CDataIntegerRangeComparator
java.lang.Object
com.raritantechnologies.xml.sax.filter.comparators.CDataIntegerRangeComparator
- All Implemented Interfaces:
- CDataComparator
- public class CDataIntegerRangeComparator
- extends java.lang.Object
- implements CDataComparator
CDataComparator that expects data to be an integer. It filters based on a number
range used to construct the object. Works with the
ProgrammableSAXFilter.
XML Configuration Schema:
<CDataComparator class="com.raritantechnologies.xml.sax.filter.comparators.CDataIntegerRangeComparator"
low="[ low integer]"
high=[ high integer ]" />
Developed by
Raritan Technologies Inc..
- Author:
- Ted Sullivan
|
Method Summary |
void |
initialize(org.w3c.dom.Element elem)
|
boolean |
matches(char[] source,
int start,
int length)
determines if the character data source matches the criteria of this
comparator. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CDataIntegerRangeComparator
public CDataIntegerRangeComparator()
CDataIntegerRangeComparator
public CDataIntegerRangeComparator(int low,
int high)
CDataIntegerRangeComparator
public CDataIntegerRangeComparator(int low,
int high,
boolean deleteInRange)
matches
public boolean matches(char[] source,
int start,
int length)
- Description copied from interface:
CDataComparator
- determines if the character data source matches the criteria of this
comparator.
- Specified by:
matches in interface CDataComparator
- Parameters:
source - character array obtained from original SAX parser.start - position of the first character in the array to
consider.length - number of characters to consider.
- Returns:
- true if the characters match the criteria defined
by this comparator. false otherwise.
initialize
public void initialize(org.w3c.dom.Element elem)
- Specified by:
initialize in interface CDataComparator