public class SearchRequestContainer
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private int |
count
The number of entries already sent
|
private org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> |
cursor
The Cursor associated with the searchRequest
|
private long |
initialTime
The SearchRequest reception date
|
private org.apache.directory.api.ldap.model.message.SearchRequest |
searchRequest
The SearchRequest
|
private long |
sizeLimit
The maximum number of entries we can send
|
private long |
timeLimit
The time limit
|
| Constructor and Description |
|---|
SearchRequestContainer(org.apache.directory.api.ldap.model.message.SearchRequest searchRequest,
org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> cursor)
Create an instance of the container with the SearchRequest and its limit.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getCount() |
org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> |
getCursor() |
long |
getInitialTime() |
org.apache.directory.api.ldap.model.message.SearchRequest |
getSearchRequest() |
long |
getSizeLimit() |
int |
getTimeLimit() |
void |
increment() |
boolean |
isSizeLimitReached()
Check the size limit
|
boolean |
isTimeLimitReached()
Check if we have reached the time limit
|
java.lang.String |
toString() |
private org.apache.directory.api.ldap.model.message.SearchRequest searchRequest
private long sizeLimit
private int count
private long timeLimit
private long initialTime
private org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> cursor
public SearchRequestContainer(org.apache.directory.api.ldap.model.message.SearchRequest searchRequest,
org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> cursor)
searchRequest - The SearchRequest instancesizeLimit - The size limittimeLimit - The time limitpublic org.apache.directory.api.ldap.model.message.SearchRequest getSearchRequest()
public long getSizeLimit()
public int getCount()
public boolean isSizeLimitReached()
public void increment()
count - the count to setpublic int getTimeLimit()
public boolean isTimeLimitReached()
public long getInitialTime()
public org.apache.directory.api.ldap.model.cursor.Cursor<org.apache.directory.api.ldap.model.entry.Entry> getCursor()
public java.lang.String toString()
toString in class java.lang.ObjectObject.toString()