public class ModifyRequestImpl extends AbstractAbandonableRequest implements ModifyRequest
Constructor and Description |
---|
ModifyRequestImpl()
Creates a ModifyRequest implementing object used to modify the
attributes of an entry.
|
Modifier and Type | Method and Description |
---|---|
ModifyRequest |
add(Attribute attr)
marks a given attribute for addition in the target entry.
|
ModifyRequest |
add(String attributeName,
byte[]... attributeValue) |
ModifyRequest |
add(String attributeName,
String... attributeValue)
marks a given attribute for addition in the target entry with the
given values.
|
ModifyRequest |
addAllControls(Control[] controls)
Adds an array of controls to this Message.
|
ModifyRequest |
addControl(Control control)
Adds a control to this Message.
|
ModifyRequest |
addModification(Attribute attr,
ModificationOperation modOp)
Add a modification
|
ModifyRequest |
addModification(Modification mod)
Adds a ModificationItem to the set of modifications composing this modify
request.
|
boolean |
equals(Object obj)
Checks to see if ModifyRequest stub equals another by factoring in checks
for the name and modification items of the request.
|
Collection<Modification> |
getModifications()
Gets an immutable Collection of modification items representing the
atomic changes to perform on the candidate entry to modify.
|
Dn |
getName()
Gets the distinguished name of the entry to be modified by this request.
|
MessageTypeEnum |
getResponseType()
Gets the protocol response message type for this request which produces
at least one response.
|
ModifyResponse |
getResultResponse()
The result containing response for this request.
|
int |
hashCode() |
ModifyRequest |
increment(Attribute attr)
marks a given attribute for increment by 1 in the target entry.
|
ModifyRequest |
increment(Attribute attr,
int increment)
marks a given attribute for increment in the target entry.
|
ModifyRequest |
increment(String attributeName)
marks a given attribute for increment by 1 in the target entry.
|
ModifyRequest |
increment(String attributeName,
int increment)
marks a given attribute for increment in the target entry.
|
ModifyRequest |
remove(Attribute attr)
marks a given attribute for removal from the target entry.
|
ModifyRequest |
remove(String attributeName)
marks a given attribute name for removal from the target entry.
|
ModifyRequest |
remove(String attributeName,
byte[]... attributeValue) |
ModifyRequest |
remove(String attributeName,
String... attributeValue)
marks a given attribute for removal with the given
values from the target entry.
|
ModifyRequest |
removeControl(Control control)
Deletes a control removing it from this Message.
|
ModifyRequest |
removeModification(Modification mod)
Removes a ModificationItem to the set of modifications composing this
modify request.
|
ModifyRequest |
replace(Attribute attr)
marks a given attribute for replacement in the target entry.
|
ModifyRequest |
replace(String attributeName) |
ModifyRequest |
replace(String attributeName,
byte[]... attributeValue) |
ModifyRequest |
replace(String attributeName,
String... attributeValue)
marks a given attribute for replacement with the given
values in the target entry.
|
ModifyRequest |
setMessageId(int messageId)
Sets the Message ID for this request
|
ModifyRequest |
setName(Dn name)
Sets the distinguished name of the entry to be modified by this request.
|
String |
toString()
Get a String representation of a ModifyRequest
|
abandon, addAbandonListener, isAbandoned
hasResponse
get, getControl, getControls, getMessageId, getType, hasControl, put, toString
hasResponse
get, getControl, getControls, getMessageId, getType, hasControl, put
abandon, addAbandonListener, isAbandoned
public ModifyRequestImpl()
public Collection<Modification> getModifications()
getModifications
in interface ModifyRequest
public Dn getName()
getName
in interface ModifyRequest
public ModifyRequest setName(Dn name)
setName
in interface ModifyRequest
name
- the Dn of the modified entry.public ModifyRequest addModification(Modification mod)
addModification
in interface ModifyRequest
mod
- a Modification to add.public ModifyRequest addModification(Attribute attr, ModificationOperation modOp)
addModification
in interface ModifyRequest
attr
- The attribute to be modifiedmodOp
- The operationpublic ModifyRequest add(String attributeName, String... attributeValue)
add
in interface ModifyRequest
attributeName
- name of the attribute to be addedattributeValue
- values of the attributepublic ModifyRequest add(String attributeName, byte[]... attributeValue)
add
in interface ModifyRequest
attributeName
- name of the attribute to be addedattributeValue
- values of the attributeadd(String, String...)
public ModifyRequest add(Attribute attr)
add
in interface ModifyRequest
attr
- the attribute to be addedpublic ModifyRequest replace(String attributeName)
replace
in interface ModifyRequest
attributeName
- name of the attribute to be addedreplace(String, String...)
public ModifyRequest replace(String attributeName, String... attributeValue)
replace
in interface ModifyRequest
attributeName
- name of the attribute to be addedattributeValue
- values of the attributepublic ModifyRequest replace(String attributeName, byte[]... attributeValue)
replace
in interface ModifyRequest
attributeName
- name of the attribute to be addedattributeValue
- values of the attributereplace(String, String...)
public ModifyRequest replace(Attribute attr)
replace
in interface ModifyRequest
attr
- the attribute to be addedpublic ModifyRequest removeModification(Modification mod)
removeModification
in interface ModifyRequest
mod
- a Modification to remove.public ModifyRequest remove(String attributeName, String... attributeValue)
remove
in interface ModifyRequest
attributeName
- name of the attribute to be removedattributeValue
- values of the attributepublic ModifyRequest remove(String attributeName, byte[]... attributeValue)
remove
in interface ModifyRequest
attributeName
- name of the attribute to be addedattributeValue
- values of the attributeModifyRequest.remove(String, String...)
public ModifyRequest remove(Attribute attr)
remove
in interface ModifyRequest
attr
- the attribute to be removedpublic ModifyRequest remove(String attributeName)
remove
in interface ModifyRequest
attributeName
- the attribute to be removedpublic ModifyRequest increment(String attributeName)
increment
in interface ModifyRequest
attributeName
- the attribute to be incrementedpublic ModifyRequest increment(String attributeName, int increment)
increment
in interface ModifyRequest
attributeName
- the attribute to be incrementedincrement
- The increment value (>=1)public ModifyRequest increment(Attribute attr)
increment
in interface ModifyRequest
attr
- the attribute to be incrementedpublic ModifyRequest increment(Attribute attr, int increment)
increment
in interface ModifyRequest
attr
- the attribute to be incrementedincrement
- The increment value (>=1)public ModifyRequest setMessageId(int messageId)
setMessageId
in interface Message
setMessageId
in interface ModifyRequest
setMessageId
in class AbstractMessage
messageId
- The message Idpublic ModifyRequest addControl(Control control)
addControl
in interface Message
addControl
in interface ModifyRequest
addControl
in class AbstractMessage
control
- the control to add.public ModifyRequest addAllControls(Control[] controls)
addAllControls
in interface Message
addAllControls
in interface ModifyRequest
addAllControls
in class AbstractMessage
controls
- the controls to add.public ModifyRequest removeControl(Control control)
removeControl
in interface Message
removeControl
in interface ModifyRequest
removeControl
in class AbstractMessage
control
- the control to remove.public MessageTypeEnum getResponseType()
getResponseType
in interface SingleReplyRequest
public ModifyResponse getResultResponse()
getResultResponse
in interface ResultResponseRequest
public int hashCode()
hashCode
in class AbstractRequest
Object.hashCode()
public boolean equals(Object obj)
equals
in class AbstractRequest
obj
- the object to compare this ModifyRequest toCopyright © 2003–2023 The Apache Software Foundation. All rights reserved.