Package org.ldaptive.control
Class EntryChangeNotificationControl
java.lang.Object
org.ldaptive.control.AbstractControl
org.ldaptive.control.EntryChangeNotificationControl
- All Implemented Interfaces:
Control
,ResponseControl
Response control for persistent search. See http://tools.ietf.org/id/draft-ietf-ldapext-psearch-03.txt. Control is
defined as:
EntryChangeNotification ::= SEQUENCE { changeType ENUMERATED { add (1), delete (2), modify (4), modDN (8) }, previousDN LDAPDN OPTIONAL, -- modifyDN ops. only changeNumber INTEGER OPTIONAL -- if supported }
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static class
Parse handler implementation for the change number.private static class
Parse handler implementation for the change type.private static class
Parse handler implementation for the previous dn. -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate long
change number.private PersistentSearchChangeType
change type.private static final int
hash code seed.static final String
OID of this control.private String
previous dn.Fields inherited from class org.ldaptive.control.AbstractControl
logger
-
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor.EntryChangeNotificationControl
(boolean critical) Creates a new entry change notification control.Creates a new entry change notification control.EntryChangeNotificationControl
(PersistentSearchChangeType type, boolean critical) Creates a new entry change notification control.EntryChangeNotificationControl
(PersistentSearchChangeType type, String dn, long number) Creates a new entry change notification control.EntryChangeNotificationControl
(PersistentSearchChangeType type, String dn, long number, boolean critical) Creates a new entry change notification control. -
Method Summary
Modifier and TypeMethodDescriptionvoid
Initializes this response control with the supplied BER encoded data.boolean
long
Returns the change number.Returns the change type.Returns the previous dn.int
hashCode()
Returns the hash code for this object.void
setChangeNumber
(long number) Sets the change number.void
Sets the change type.void
setPreviousDn
(String dn) Sets the previous dn.toString()
Methods inherited from class org.ldaptive.control.AbstractControl
getCriticality, getOID
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.ldaptive.control.Control
getCriticality, getOID
-
Field Details
-
OID
OID of this control.- See Also:
-
HASH_CODE_SEED
private static final int HASH_CODE_SEEDhash code seed.- See Also:
-
changeType
change type. -
previousDn
previous dn. -
changeNumber
private long changeNumberchange number.
-
-
Constructor Details
-
EntryChangeNotificationControl
public EntryChangeNotificationControl()Default constructor. -
EntryChangeNotificationControl
public EntryChangeNotificationControl(boolean critical) Creates a new entry change notification control.- Parameters:
critical
- whether this control is critical
-
EntryChangeNotificationControl
Creates a new entry change notification control.- Parameters:
type
- persistent search change type
-
EntryChangeNotificationControl
Creates a new entry change notification control.- Parameters:
type
- persistent search change typecritical
- whether this control is critical
-
EntryChangeNotificationControl
Creates a new entry change notification control.- Parameters:
type
- persistent search change typedn
- previous dnnumber
- change number
-
EntryChangeNotificationControl
public EntryChangeNotificationControl(PersistentSearchChangeType type, String dn, long number, boolean critical) Creates a new entry change notification control.- Parameters:
type
- persistent search change typedn
- previous dnnumber
- change numbercritical
- whether this control is critical
-
-
Method Details
-
getChangeType
Returns the change type.- Returns:
- change type
-
setChangeType
Sets the change type.- Parameters:
type
- change type
-
getPreviousDn
Returns the previous dn.- Returns:
- previous dn
-
setPreviousDn
Sets the previous dn.- Parameters:
dn
- previous dn
-
getChangeNumber
public long getChangeNumber()Returns the change number.- Returns:
- change number
-
setChangeNumber
public void setChangeNumber(long number) Sets the change number.- Parameters:
number
- change number
-
equals
- Overrides:
equals
in classAbstractControl
-
hashCode
public int hashCode()Description copied from class:AbstractControl
Returns the hash code for this object.- Specified by:
hashCode
in classAbstractControl
- Returns:
- hash code
-
toString
- Overrides:
toString
in classAbstractControl
-
decode
Description copied from interface:ResponseControl
Initializes this response control with the supplied BER encoded data.- Specified by:
decode
in interfaceResponseControl
- Parameters:
encoded
- BER encoded response control
-