|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.pfsw.text.AStringFilter
org.pfsw.text.StringFilterCollection
public class StringFilterCollection
A collection of IStringFilter objects that can be matched against
strings according to a defined boolean operator (AND | OR | XOR).
| Field Summary | |
|---|---|
static org.pfsw.bif.logic.BooleanOperation |
DEFAULT_OPERATION
|
| Fields inherited from interface org.pfsw.bif.text.IStringFilter |
|---|
ALL, NONE |
| Constructor Summary | |
|---|---|
StringFilterCollection()
Creates a new empty instance with default boolean operation BooleanOperation.OR. |
|
StringFilterCollection(org.pfsw.bif.logic.BooleanOperation operation)
Creates a new empty instance with specified boolean operation BooleanOperation.OR. |
|
StringFilterCollection(org.pfsw.bif.logic.BooleanOperation operation,
org.pfsw.bif.text.IStringFilter... filters)
Creates a new instance with the specified boolean operation that will be filled with the given filters. |
|
StringFilterCollection(org.pfsw.bif.text.IStringFilter... filters)
Creates a new instance with default boolean operation BooleanOperation.OR
that will be filled with the given filters. |
|
| Method Summary | |
|---|---|
void |
addFilters(org.pfsw.bif.text.IStringFilter... filters)
Adds all given filters to this collection. |
java.util.List<org.pfsw.bif.text.IStringFilter> |
asList()
Returns a list with all currently held filters. |
void |
clear()
|
protected java.util.List<org.pfsw.bif.text.IStringFilter> |
getFilterList()
|
org.pfsw.bif.logic.BooleanOperation |
getOperation()
|
boolean |
isEmpty()
|
boolean |
matches(java.lang.String aString)
|
protected boolean |
matchesAllFilters(java.lang.String aString)
|
protected boolean |
matchesAnyFilter(java.lang.String aString)
|
protected boolean |
matchesOneFilter(java.lang.String aString)
|
void |
setOperation(org.pfsw.bif.logic.BooleanOperation operation)
Set the boolean operation the filter results must combined with. |
int |
size()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final org.pfsw.bif.logic.BooleanOperation DEFAULT_OPERATION
| Constructor Detail |
|---|
public StringFilterCollection()
BooleanOperation.OR.
public StringFilterCollection(org.pfsw.bif.logic.BooleanOperation operation)
BooleanOperation.OR.
public StringFilterCollection(org.pfsw.bif.text.IStringFilter... filters)
BooleanOperation.OR
that will be filled with the given filters.
public StringFilterCollection(org.pfsw.bif.logic.BooleanOperation operation,
org.pfsw.bif.text.IStringFilter... filters)
| Method Detail |
|---|
public boolean matches(java.lang.String aString)
public void addFilters(org.pfsw.bif.text.IStringFilter... filters)
public int size()
public boolean isEmpty()
public void clear()
public org.pfsw.bif.logic.BooleanOperation getOperation()
public void setOperation(org.pfsw.bif.logic.BooleanOperation operation)
operation - The operation (must not be null).
java.lang.IllegalArgumentException - If the given operation is null.public java.util.List<org.pfsw.bif.text.IStringFilter> asList()
protected boolean matchesAnyFilter(java.lang.String aString)
protected boolean matchesAllFilters(java.lang.String aString)
protected boolean matchesOneFilter(java.lang.String aString)
protected java.util.List<org.pfsw.bif.text.IStringFilter> getFilterList()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||