|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sun.jndi.ldap.BasicControl
com.sun.jndi.ldap.ctl.VirtualListViewControl
public final class VirtualListViewControl
This class implements the LDAPv3 Request Control for virtual-list-view as defined in draft-ietf-ldapext-ldapv3-vlv-09.txt. The control's value has the following ASN.1 definition:
VirtualListViewRequest ::= SEQUENCE { beforeCount INTEGER (0 .. maxInt), afterCount INTEGER (0 .. maxInt), CHOICE { byoffset [0] SEQUENCE { offset INTEGER (0 .. maxInt), contentCount INTEGER (0 .. maxInt) } greaterThanOrEqual [1] AssertionValue } contextID OCTET STRING OPTIONAL }This control is always used in conjunction with the server-side sort control (RFC-2891).
VirtualListViewResponseControl
,
SortControl
,
Serialized FormField Summary | |
---|---|
private int |
afterCount
The number of entries after the target entry in a sublist. |
private int |
beforeCount
The number of entries before the target entry in a sublist. |
private byte[] |
cookie
A server-generated cookie. |
private int |
listSize
An estimate of the number of entries in the list. |
static java.lang.String |
OID
The virtual-list-view control's assigned object identifier is 2.16.840.1.113730.3.4.9. |
private static long |
serialVersionUID
|
private java.lang.Object |
targetAttrValue
Attribute value used to locate the target entry. |
private int |
targetOffset
An offset into the list. |
Fields inherited from class com.sun.jndi.ldap.BasicControl |
---|
criticality, id, value |
Fields inherited from interface javax.naming.ldap.Control |
---|
CRITICAL, NONCRITICAL |
Constructor Summary | |
---|---|
VirtualListViewControl(int targetPercentage,
int viewSize,
boolean criticality)
Constructs a virtual-list-view control. |
|
VirtualListViewControl(int targetOffset,
int listSize,
int beforeCount,
int afterCount,
boolean criticality)
Constructs a virtual-list-view control. |
|
VirtualListViewControl(java.lang.Object targetAttrValue,
int viewSize,
boolean criticality)
Constructs a virtual-list-view critical control. |
|
VirtualListViewControl(java.lang.Object targetAttrValue,
int beforeCount,
int afterCount,
boolean criticality)
Constructs a virtual-list-view control. |
Method Summary | |
---|---|
void |
setContextID(byte[] contextID)
Sets a server-generated cookie in the virtual-list-view request. |
private byte[] |
setEncodedValue()
|
Methods inherited from class com.sun.jndi.ldap.BasicControl |
---|
getEncodedValue, getID, isCritical |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String OID
private int beforeCount
private int afterCount
private int targetOffset
private int listSize
private java.lang.Object targetAttrValue
private byte[] cookie
private static final long serialVersionUID
Constructor Detail |
---|
public VirtualListViewControl(int targetPercentage, int viewSize, boolean criticality) throws java.io.IOException
targetPercentage
- The position of the target entry expressed as a
percentage of the list. For example, a value of
25 indicates that the target entry is at the
25 percent mark in the list.viewSize
- The number of entries to be returned in this
view of the list.criticality
- The control's criticality setting.
java.lang.IllegalArgumentException
- if targetPercentage is
outside the range 0-100.
java.io.IOException
- If a BER encoding error occurs.public VirtualListViewControl(int targetOffset, int listSize, int beforeCount, int afterCount, boolean criticality) throws java.io.IOException
targetOffset
- The position of the target entry as an offset
into the list.listSize
- An estimate of the number of entries in the list.beforeCount
- The number of entries to be returned before the
target entry.afterCount
- The number of entries to be returned after the
target entry.criticality
- The control's criticality setting.
java.lang.IllegalArgumentException
- if targetOffset, listSize,
beforeCount or afterCount are less than zero.
java.io.IOException
- If a BER encoding error occurs.public VirtualListViewControl(java.lang.Object targetAttrValue, int viewSize, boolean criticality) throws javax.naming.directory.InvalidAttributeValueException, java.io.IOException
targetAttrValue
- An attribute value used to locate the target
entry. Its attribute ID is that of the primary
sort key specified in the server-side sort
control.viewSize
- The number of entries to be returned in this
view of the list.criticality
- The control's criticality setting.
javax.naming.directory.InvalidAttributeValueException
- if
targetAttrValue is neither a String nor a byte[].
java.io.IOException
- If a BER encoding error occurs.public VirtualListViewControl(java.lang.Object targetAttrValue, int beforeCount, int afterCount, boolean criticality) throws javax.naming.directory.InvalidAttributeValueException, java.io.IOException
targetAttrValue
- An attribute value used to locate the target
entry. Its attribute ID is that of the primary
sort key specified in the server-side sort
control.beforeCount
- The number of entries to be returned before the
target entry.afterCount
- The number of entries to be returned after the
target entry.criticality
- The control's criticality setting.
javax.naming.directory.InvalidAttributeValueException
- if
targetAttrValue is neither a String nor a byte[].
java.lang.IllegalArgumentException
- if beforeCount or
afterCount are less than zero.
java.io.IOException
- If a BER encoding error occurs.Method Detail |
---|
public void setContextID(byte[] contextID) throws java.io.IOException
contextID
- A server-generated cookie.
java.io.IOException
- If a BER encoding error occurs.private byte[] setEncodedValue() throws java.io.IOException
java.io.IOException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |