APIdia Launch Partner
Top Description Fields Constructors Methods
com.sun.jndi.ldap

public final Class EntryChangeResponseControl

extends BasicControl
Class Inheritance
Imports
java.io.IOException, javax.naming.*, javax.naming.directory.*

This class implements the LDAPv3 Response Control for entry-change notification as defined in draft-ietf-ldapext-psearch-02.txt. The control's value has the following ASN.1 definition:

    EntryChangeNotification ::= SEQUENCE {
        changeType ENUMERATED {
            add              (1),
            delete           (2),
            modify           (4),
            modDN            (8)
        },
        previousDN   LDAPDN OPTIONAL,        -- modifyDN ops. only
        changeNumber INTEGER OPTIONAL,       -- if supported
   }

See Also
PersistentSearchControl, DefaultResponseControlFactory

Field Summary

Modifier and TypeField and Description
public static final int
ADD

Indicates an entry which has been added.

private long
changeNumber

The change number (if supported by the server).

private int
changeType

The type of change that occurred.

public static final int
DELETE

Indicates an entry which has been deleted.

public static final int
MODIFY

Indicates an entry which has been modified.

public static final String
OID

The entry-change response control's assigned object identifier is 2.16.840.1.113730.3.4.7.

private String
previousDN

The previous distinguished name (only applies to RENAME changes).

public static final int
RENAME

Indicates an entry which has been renamed.

private static final long
Inherited from com.sun.jndi.ldap.BasicControl:
criticalityidvalue

Constructor Summary

AccessConstructor and Description
public
EntryChangeResponseControl(String
The control's object identifier string.
id
,
boolean
The control's criticality.
criticality
,
byte[]
The control's ASN.1 BER encoded value. May be null.
value
)

Constructs a new instance of EntryChangeResponseControl.

Method Summary

Modifier and TypeMethod and Description
public long

Returns:

The change number or -1 if unsupported.
getChangeNumber
()

Retrieves the change number assigned by the server for this change.

public int

Returns:

The type of change.
getChangeType
()

Retrieves the type of change that occurred.

public String

Returns:

The previous distinguished name or null if not applicable.
getPreviousDN
()

Retrieves the previous distinguished name of the entry before it was renamed and/or moved.

Inherited from com.sun.jndi.ldap.BasicControl:
getEncodedValuegetIDisCritical

Field Detail

ADDback to summary
public static final int ADD

Indicates an entry which has been added.

changeNumberback to summary
private long changeNumber

The change number (if supported by the server).

changeTypeback to summary
private int changeType

The type of change that occurred.

DELETEback to summary
public static final int DELETE

Indicates an entry which has been deleted.

MODIFYback to summary
public static final int MODIFY

Indicates an entry which has been modified.

OIDback to summary
public static final String OID

The entry-change response control's assigned object identifier is 2.16.840.1.113730.3.4.7.

previousDNback to summary
private String previousDN

The previous distinguished name (only applies to RENAME changes).

RENAMEback to summary
public static final int RENAME

Indicates an entry which has been renamed.

serialVersionUIDback to summary
private static final long serialVersionUID

Hides com.sun.jndi.ldap.BasicControl.serialVersionUID.

Constructor Detail

EntryChangeResponseControlback to summary
public EntryChangeResponseControl(String id, boolean criticality, byte[] value) throws IOException

Constructs a new instance of EntryChangeResponseControl.

Parameters
id:String

The control's object identifier string.

criticality:boolean

The control's criticality.

value:byte[]

The control's ASN.1 BER encoded value. May be null.

Exceptions
IOException:
if an error is encountered while decoding the control's value.

Method Detail

getChangeNumberback to summary
public long getChangeNumber()

Retrieves the change number assigned by the server for this change. Returns -1 if this feature is not supported by the server.

Returns:long

The change number or -1 if unsupported.

getChangeTypeback to summary
public int getChangeType()

Retrieves the type of change that occurred.

Returns:int

The type of change.

getPreviousDNback to summary
public String getPreviousDN()

Retrieves the previous distinguished name of the entry before it was renamed and/or moved. This method applies only to RENAME changes.

Returns:String

The previous distinguished name or null if not applicable.