public final class FilterEncoder
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private static java.lang.String[] |
EMPTY |
| Modifier | Constructor and Description |
|---|---|
private |
FilterEncoder() |
| Modifier and Type | Method and Description |
|---|---|
static java.lang.String |
encodeFilterValue(java.lang.String value)
Handles encoding of special characters in LDAP search filter assertion values using the
<valueencoding> rule as described in RFC 4515.
|
static java.lang.String |
format(java.lang.String filterTemplate,
java.lang.String... values)
Formats a filter and handles encoding of special characters in the value arguments using the
<valueencoding> rule as described in RFC 4515.
|
public static java.lang.String format(java.lang.String filterTemplate,
java.lang.String... values)
throws java.lang.IllegalArgumentException
Example of filter template format: (&(cn={0})(uid={1}))
filterTemplate - the filter with placeholdersvalues - the values to encode and substitutejava.lang.IllegalArgumentException - if the number of values does not match the number of placeholders in the templatepublic static java.lang.String encodeFilterValue(java.lang.String value)
value - Right hand side of "attrId=value" assertion occurring in an LDAP search filter.value