netscape.ldap.controls
Class LDAPVirtualListResponse
- Cloneable, java.io.Serializable
public class LDAPVirtualListResponse
Represents control data for returning paged results from a search.
1.0
VirtualListViewResponse ::= SEQUENCE {
targetPosition INTEGER (0 .. maxInt),
contentCount INTEGER (0 .. maxInt),
virtualListViewResult ENUMERATED {
success (0),
operatonsError (1),
timeLimitExceeded (3),
adminLimitExceeded (11),
insufficientAccessRights (50),
busy (51),
unwillingToPerform (53),
sortControlMissing (60),
offsetRangeError (61),
other (80)
},
contextID OCTET STRING OPTIONAL
}
VIRTUALLISTRESPONSE
public static final String VIRTUALLISTRESPONSE
LDAPVirtualListResponse
public LDAPVirtualListResponse(String oid,
boolean critical,
byte[] value)
throws LDAPException
Contructs an LDAPVirtualListResponse
object.
oid
- this parameter must be equal to
LDAPVirtualListResponse.VIRTUALLISTRESPONSE
or an
LDAPException
is throwncritical
- true
if this control is criticalvalue
- the value associated with this control
LDAPException
- If oid is not
LDAPVirtualListResponse.VIRTUALLISTRESPONSE
.
LDAPVirtualListResponse
public LDAPVirtualListResponse(byte[] value)
Constructs a new LDAPVirtualListResponse
object.
value
- a BER encoded byte array
getContentCount
public int getContentCount()
Gets the size of the virtual result set.
- the size of the virtual result set, or -1 if not known.
getContext
public String getContext()
Gets the context cookie, if any.
- the result context cookie.
getFirstPosition
public int getFirstPosition()
Gets the index of the first entry returned.
- the index of the first entry returned.
getResultCode
public int getResultCode()
Gets the result code.
parseResponse
public static LDAPVirtualListResponse parseResponse(LDAPControl[] controls)
LDAPVirtualListResponse controls are now automatically
instantiated.
Returns a control returned on a VLV search.
controls
- an array of controls that may include a VLV
results control
- the control, if any; otherwise null.