|
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.jndi.toolkit.dir.SearchFilter
public class SearchFilter
A class for parsing LDAP search filters (defined in RFC 1960, 2254)
| Field Summary | |
|---|---|
protected static char |
AND_TOKEN
|
protected static char |
APPROX_TOKEN
|
protected static char |
BEGIN_FILTER_TOKEN
|
protected static boolean |
debug
|
protected static char |
END_FILTER_TOKEN
|
protected static char |
EQUAL_TOKEN
|
protected static char |
EXTEND_TOKEN
|
protected static char |
GREATER_TOKEN
|
protected static char |
LESS_TOKEN
|
protected static char |
NOT_TOKEN
|
protected static char |
OR_TOKEN
|
protected static char |
WILDCARD_TOKEN
|
| Constructor Summary | |
|---|---|
SearchFilter(String filter)
|
|
| Method Summary | |
|---|---|
boolean |
check(Attributes targetAttrs)
Determines whether an attribute passes the filter. |
protected void |
consumeChar()
|
protected void |
consumeChars(int i)
|
protected com.sun.jndi.toolkit.dir.SearchFilter.StringFilter |
createNextFilter()
|
static int |
findUnescaped(char ch,
String val,
int start)
Finds the first occurrence of ch in val starting from position start. |
static String |
format(Attributes attrs)
Creates an LDAP filter as a conjuction of the attributes supplied. |
static String |
format(String expr,
Object[] args)
Formats the expression expr using arguments from the array args. |
protected char |
getCurrentChar()
|
protected void |
normalizeFilter()
|
protected char |
relCharAt(int i)
|
protected int |
relIndexOf(int ch)
|
protected String |
relSubstring(int beginIndex,
int endIndex)
|
static Attributes |
selectAttributes(Attributes originals,
String[] attrIDs)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final boolean debug
protected static final char BEGIN_FILTER_TOKEN
protected static final char END_FILTER_TOKEN
protected static final char AND_TOKEN
protected static final char OR_TOKEN
protected static final char NOT_TOKEN
protected static final char EQUAL_TOKEN
protected static final char APPROX_TOKEN
protected static final char LESS_TOKEN
protected static final char GREATER_TOKEN
protected static final char EXTEND_TOKEN
protected static final char WILDCARD_TOKEN
| Constructor Detail |
|---|
public SearchFilter(String filter)
throws InvalidSearchFilterException
InvalidSearchFilterException| Method Detail |
|---|
public boolean check(Attributes targetAttrs)
throws NamingException
AttrFilter
check in interface AttrFilterNamingExceptionprotected void normalizeFilter()
protected com.sun.jndi.toolkit.dir.SearchFilter.StringFilter createNextFilter()
throws InvalidSearchFilterException
InvalidSearchFilterExceptionprotected char getCurrentChar()
protected char relCharAt(int i)
protected void consumeChar()
protected void consumeChars(int i)
protected int relIndexOf(int ch)
protected String relSubstring(int beginIndex,
int endIndex)
public static String format(Attributes attrs)
throws NamingException
NamingException
public static int findUnescaped(char ch,
String val,
int start)
public static String format(String expr,
Object[] args)
throws NamingException
{i} specifies the i'th element from
the array args is to be substituted for the
string "{i}".
To escape '{' or '}' (or any other character), use '\'.
Uses getEncodedStringRep() to do encoding.
NamingException
public static Attributes selectAttributes(Attributes originals,
String[] attrIDs)
throws NamingException
NamingException
|
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||