Package org.springframework.ldap.filter
Class EqualsFilter
java.lang.Object
org.springframework.ldap.filter.AbstractFilter
org.springframework.ldap.filter.CompareFilter
org.springframework.ldap.filter.EqualsFilter
- All Implemented Interfaces:
Filter
- Direct Known Subclasses:
LikeFilter
,WhitespaceWildcardsFilter
A filter for 'equals'. The following code:
EqualsFilter filter = new EqualsFilter("cn", "Some CN"); System.out.println(filter.encode());would result in:
(cn=Some CN)
-
Constructor Summary
ConstructorsConstructorDescriptionEqualsFilter
(String attribute, int value) Convenience constructor for int values.EqualsFilter
(String attribute, String value) -
Method Summary
Modifier and TypeMethodDescriptionprotected String
Implement this method in subclass to return a String representing the operator.Methods inherited from class org.springframework.ldap.filter.CompareFilter
encode, encodeValue, equals, hashCode
Methods inherited from class org.springframework.ldap.filter.AbstractFilter
encode, toString
-
Constructor Details
-
EqualsFilter
-
EqualsFilter
Convenience constructor for int values.- Parameters:
attribute
- Name of attribute in filter.value
- The value of the attribute in the filter.
-
-
Method Details
-
getCompareString
Description copied from class:CompareFilter
Implement this method in subclass to return a String representing the operator. ThegetCompareString()
would for example return an equals sign, "=".- Specified by:
getCompareString
in classCompareFilter
- Returns:
- the String to use as operator in the comparison for the specific subclass.
-