public class PresentFilter extends AbstractFilter
'present' it must contain a value. Attributes that do
not contain a value are 'NOT present'. To filter on attributes that
are 'NOT present' use the NotPresentFilter or use this filter
in combination with a NotFilter .
PresentFilter filter = new PresentFilter("foo");
System.out.println(filter.encode());
would result in:
(foo=*)
| Constructor and Description |
|---|
PresentFilter(String attribute)
Creates a new instance of a present filter for a particular attribute.
|
| Modifier and Type | Method and Description |
|---|---|
StringBuffer |
encode(StringBuffer buff)
Encodes the filter to a StringBuffer.
|
boolean |
equals(Object o)
All filters must implement equals.
|
int |
hashCode()
All filters must implement hashCode.
|
encode, toStringpublic PresentFilter(String attribute)
attribute - the attribute expected to be present (ie, contains a
value).public StringBuffer encode(StringBuffer buff)
Filterbuff - The StringBuffer to encode the filter topublic boolean equals(Object o)
Filter