|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--netscape.ldap.LDAPConstraints | +--netscape.ldap.LDAPSearchConstraints
Represents a set of search preferences.
You can set these preferences for a particular search
by creating an LDAPSearchConstraints
object,
specifying your preferences, and passing the object to
the LDAPConnection.search
method.
Constructor Summary | |
LDAPSearchConstraints()
Constructs an LDAPSearchConstraints object that specifies
the default set of search constraints. |
|
LDAPSearchConstraints(int msLimit,
int dereference,
int maxResults,
boolean doReferrals,
int batchSize,
LDAPRebind rebind_proc,
int hop_limit)
Constructs a new LDAPSearchConstraints object and allows you
to specify the search constraints in that object. |
|
LDAPSearchConstraints(int msLimit,
int timeLimit,
int dereference,
int maxResults,
boolean doReferrals,
int batchSize,
LDAPBind bind_proc,
int hop_limit)
Constructs a new LDAPSearchConstraints object and allows you
to specify the search constraints in that object. |
|
LDAPSearchConstraints(int msLimit,
int timeLimit,
int dereference,
int maxResults,
boolean doReferrals,
int batchSize,
LDAPRebind rebind_proc,
int hop_limit)
Constructs a new LDAPSearchConstraints object and allows you
to specify the search constraints in that object. |
Method Summary | |
java.lang.Object |
clone()
Makes a copy of an existing set of search constraints. |
int |
getBatchSize()
Returns the suggested number of results to return at a time during search. |
int |
getDereference()
Specifies how aliases should be dereferenced. |
int |
getMaxBacklog()
Deprecated. Use LDAPConnection.setOption() |
int |
getMaxResults()
Returns the maximum number of search results that are to be returned; 0 means there is no limit. |
int |
getServerTimeLimit()
Returns the maximum number of seconds to wait for the server to spend on a search operation.If 0, there is no time limit. |
void |
setBatchSize(int batchSize)
Sets the suggested number of results to return at a time during search. |
void |
setDereference(int dereference)
Sets a preference indicating how aliases should be dereferenced. |
void |
setMaxBacklog(int backlog)
Deprecated. Use LDAPConnection.getOption() |
void |
setMaxResults(int maxResults)
Sets the maximum number of search results to return; 0 means there is no limit. |
void |
setServerTimeLimit(int limit)
Sets the maximum number of seconds for the server to spend returning search results. |
java.lang.String |
toString()
Return a string representation of the object for debugging |
Methods inherited from class netscape.ldap.LDAPConstraints |
getBindProc,
getClientControls,
getHopLimit,
getRebindProc,
getReferrals,
getServerControls,
getTimeLimit,
setBindProc,
setClientControls,
setClientControls,
setHopLimit,
setRebindProc,
setReferrals,
setServerControls,
setServerControls,
setTimeLimit |
Methods inherited from class java.lang.Object |
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Constructor Detail |
public LDAPSearchConstraints()
LDAPSearchConstraints
object that specifies
the default set of search constraints.public LDAPSearchConstraints(int msLimit, int dereference, int maxResults, boolean doReferrals, int batchSize, LDAPRebind rebind_proc, int hop_limit)
LDAPSearchConstraints
object and allows you
to specify the search constraints in that object.
msLimit
- maximum time in milliseconds to wait for results (0
by default, which means that there is no maximum time limit)dereference
- either LDAPv2.DEREF_NEVER
,
LDAPv2.DEREF_FINDING
,
LDAPv2.DEREF_SEARCHING
, or
LDAPv2.DEREF_ALWAYS
(see LDAPConnection.setOption).
LDAPv2.DEREF_NEVER
is the default.maxResults
- maximum number of search results to return
(1000 by default)doReferrals
- specify true
to follow referrals
automatically, or false
to throw an
LDAPReferralException
error if the server sends back
a referral (false
by default)batchSize
- specify the number of results to return at a time
(1 by default)rebind_proc
- specifies the object of the class that
implements the LDAPRebind
interface (you need to
define this class). The object will be used when the client
follows referrals automatically. The object provides the client
with a method for getting the distinguished name and password
used to authenticate to another LDAP server during a referral.
(This field is null
by default.)hop_limit
- maximum number of referrals to follow in a
sequence when attempting to resolve a requestLDAPConnection.setOption(int, java.lang.Object)
,
LDAPConnection.search(netscape.ldap.LDAPUrl, netscape.ldap.LDAPSearchConstraints)
,
LDAPConnection.search(java.lang.String, int, java.lang.String, java.lang.String[], boolean, netscape.ldap.LDAPSearchConstraints)
public LDAPSearchConstraints(int msLimit, int timeLimit, int dereference, int maxResults, boolean doReferrals, int batchSize, LDAPRebind rebind_proc, int hop_limit)
LDAPSearchConstraints
object and allows you
to specify the search constraints in that object.
msLimit
- maximum time in milliseconds to wait for results (0
by default, which means that there is no maximum time limit)timeLimit
- maximum time in seconds for the server to spend
processing a search request (the default value is 0, indicating that there
is no limit)dereference
- either LDAPv2.DEREF_NEVER
,
LDAPv2.DEREF_FINDING
,
LDAPv2.DEREF_SEARCHING
, or
LDAPv2.DEREF_ALWAYS
(see LDAPConnection.setOption).
LDAPv2.DEREF_NEVER
is the default.maxResults
- maximum number of search results to return
(1000 by default)doReferrals
- specify true
to follow referrals
automatically, or false
to throw an
LDAPReferralException
error if the server sends back
a referral (false
by default)batchSize
- specify the number of results to return at a time
(1 by default)rebind_proc
- specifies the object that
implements the LDAPRebind
interface.
The object will be used when the client
follows referrals automatically. The object provides the client
with a method for getting the distinguished name and password
used to authenticate to another LDAP server during a referral.
(This field is null
by default.)hop_limit
- maximum number of referrals to follow in a
sequence when attempting to resolve a requestLDAPConnection.setOption(int, java.lang.Object)
,
LDAPConnection.search(netscape.ldap.LDAPUrl, netscape.ldap.LDAPSearchConstraints)
,
LDAPConnection.search(java.lang.String, int, java.lang.String, java.lang.String[], boolean, netscape.ldap.LDAPSearchConstraints)
public LDAPSearchConstraints(int msLimit, int timeLimit, int dereference, int maxResults, boolean doReferrals, int batchSize, LDAPBind bind_proc, int hop_limit)
LDAPSearchConstraints
object and allows you
to specify the search constraints in that object.
msLimit
- maximum time in milliseconds to wait for results (0
by default, which means that there is no maximum time limit)timeLimit
- maximum time in seconds for the server to spend
processing a search request (the default value is 0, indicating that there
is no limit)dereference
- either LDAPv2.DEREF_NEVER
,
LDAPv2.DEREF_FINDING
,
LDAPv2.DEREF_SEARCHING
, or
LDAPv2.DEREF_ALWAYS
(see LDAPConnection.setOption).
LDAPv2.DEREF_NEVER
is the default.maxResults
- maximum number of search results to return
(1000 by default)doReferrals
- specify true
to follow referrals
automatically, or false
to throw an
LDAPReferralException
error if the server sends back
a referral (false
by default)batchSize
- specify the number of results to return at a time
(1 by default)bind_proc
- specifies the object that
implements the LDAPBind
interface (you need to
define this class). The object will be used to authenticate
to the server on referrals.
(This field is null
by default.)hop_limit
- maximum number of referrals to follow in a
sequence when attempting to resolve a requestLDAPConnection.setOption(int, java.lang.Object)
,
LDAPConnection.search(netscape.ldap.LDAPUrl, netscape.ldap.LDAPSearchConstraints)
,
LDAPConnection.search(java.lang.String, int, java.lang.String, java.lang.String[], boolean, netscape.ldap.LDAPSearchConstraints)
Method Detail |
public int getServerTimeLimit()
public int getDereference()
LDAPv2.DEREF_NEVER
to
never follow ("dereference") aliases,
LDAPv2.DEREF_FINDING
to dereference when finding
the starting point for the search (but not when searching
under that starting entry), LDAPv2.DEREF_SEARCHING
to dereference when searching the entries beneath the
starting point of the search (but not when finding the starting
entry), or LDAPv2.DEREF_ALWAYS
to always
dereference aliases.public int getMaxResults()
public int getBatchSize()
public void setServerTimeLimit(int limit)
limit
- maximum number of seconds for the server to spend.
(0 by default, which means that there is no maximum time limit.)public void setDereference(int dereference)
dereference
- LDAPv2.DEREF_NEVER
to
never follow ("dereference") aliases,
LDAPv2.DEREF_FINDING
to dereference when finding
the starting point for the search (but not when searching
under that starting entry), LDAPv2.DEREF_SEARCHING
to dereference when searching the entries beneath the
starting point of the search (but not when finding the starting
entry), or LDAPv2.DEREF_ALWAYS
to always
dereference aliasespublic void setMaxResults(int maxResults)
maxResults
- maximum number of search results to returnpublic void setBatchSize(int batchSize)
batchSize
- number of results to return at a timepublic void setMaxBacklog(int backlog)
LDAPConnection.getOption()
backlog
- the maximum number of unread entries per listenerpublic int getMaxBacklog()
LDAPConnection.setOption()
public java.lang.Object clone()
public java.lang.String toString()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |