public class AddOperationBasis extends AbstractOperation implements PreParseAddOperation, AddOperation, PostResponseAddOperation
cancelRequest, cancelResult, clientConnection, messageID, NO_RESPONSE_CONTROLS, operationIDLOCALBACKENDOPERATIONS| Constructor and Description |
|---|
AddOperationBasis(ClientConnection clientConnection,
long operationID,
int messageID,
List<Control> requestControls,
org.forgerock.opendj.ldap.ByteString rawEntryDN,
List<RawAttribute> rawAttributes)
Creates a new add operation with the provided information.
|
AddOperationBasis(ClientConnection clientConnection,
long operationID,
int messageID,
List<Control> requestControls,
DN entryDN,
Map<ObjectClass,String> objectClasses,
Map<AttributeType,List<Attribute>> userAttributes,
Map<AttributeType,List<Attribute>> operationalAttributes)
Creates a new add operation with the provided information.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addObjectClass(ObjectClass objectClass,
String name)
Adds the provided objectclass to the entry to add.
|
void |
addRawAttribute(RawAttribute rawAttribute)
Adds the provided attribute to the set of raw attributes for this
add operation.
|
void |
addResponseControl(Control control)
Adds the provided control to the set of controls to include in
the response to the client.
|
DN |
getEntryDN()
Retrieves the DN of the entry to add.
|
Entry |
getEntryToAdd()
Retrieves the entry to be added to the server.
|
Map<ObjectClass,String> |
getObjectClasses()
Retrieves the set of processed objectclasses for the entry to add.
|
Map<AttributeType,List<Attribute>> |
getOperationalAttributes()
Retrieves the set of processed operational attributes for the entry to add.
|
OperationType |
getOperationType()
Retrieves the operation type for this operation.
|
DN |
getProxiedAuthorizationDN()
Retrieves the proxied authorization DN for this operation if proxied
authorization has been requested.
|
List<RawAttribute> |
getRawAttributes()
Retrieves the set of attributes in their raw, unparsed form as
read from the client request.
|
org.forgerock.opendj.ldap.ByteString |
getRawEntryDN()
Retrieves the DN of the entry to add in a raw, unparsed form as
it was included in the request.
|
ArrayList<Control> |
getResponseControls()
Retrieves the set of controls to include in the response to the
client.
|
Map<AttributeType,List<Attribute>> |
getUserAttributes()
Retrieves the set of processed user attributes for the entry to add.
|
void |
removeAttribute(AttributeType attributeType)
Removes the specified attribute from the entry to add.
|
void |
removeObjectClass(ObjectClass objectClass)
Removes the provided objectclass from the entry to add.
|
void |
removeResponseControl(Control control)
Removes the provided control from the set of controls to include
in the response to the client.
|
void |
run()
Performs the work of actually processing this operation.
|
void |
setAttribute(AttributeType attributeType,
List<Attribute> attributeList)
Sets the specified attribute in the entry to add, overwriting any existing
attribute of the specified type if necessary.
|
void |
setProxiedAuthorizationDN(DN proxiedAuthorizationDN)
Set the proxied authorization DN for this operation if proxied
authorization has been requested.
|
void |
setRawAttributes(List<RawAttribute> rawAttributes)
Replaces the set of raw attributes for this add operation.
|
void |
setRawEntryDN(org.forgerock.opendj.ldap.ByteString rawEntryDN)
Specifies the raw entry DN for the entry to add.
|
void |
toString(StringBuilder buffer)
Appends a string representation of this operation to the provided
buffer.
|
void |
updateOperationErrMsgAndResCode()
Updates the error message and the result code of the operation.
|
abort, addAdditionalLogItem, addRequestControl, appendErrorMessage, appendMaskedErrorMessage, cancel, checkIfCanceled, disconnectClient, dontSynchronize, equals, getAdditionalLogItems, getAttachment, getAttachments, getAuthorizationDN, getAuthorizationEntry, getCancelRequest, getCancelResult, getClientConnection, getConnectionID, getErrorMessage, getMaskedErrorMessage, getMaskedResultCode, getMatchedDN, getMessageID, getOperationID, getProcessingNanoTime, getProcessingStartTime, getProcessingStopTime, getProcessingTime, getReferralURLs, getRequestControl, getRequestControls, getResultCode, hashCode, invokePostResponseCallbacks, isInnerOperation, isInternalOperation, isSynchronizationOperation, operationCompleted, processOperationResult, processOperationResult, registerPostResponseCallback, removeAttachment, setAttachment, setAttachments, setAuthorizationEntry, setDontSynchronize, setErrorMessage, setInnerOperation, setInternalOperation, setMaskedErrorMessage, setMaskedResultCode, setMatchedDN, setProcessingStartTime, setProcessingStopTime, setReferralURLs, setResponseData, setResultCode, setSynchronizationOperation, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitaddAdditionalLogItem, addRequestControl, appendErrorMessage, getAdditionalLogItems, getErrorMessage, setErrorMessageabort, addAdditionalLogItem, addRequestControl, appendErrorMessage, appendMaskedErrorMessage, cancel, checkIfCanceled, disconnectClient, dontSynchronize, getAdditionalLogItems, getAttachment, getAttachments, getAuthorizationDN, getAuthorizationEntry, getCancelRequest, getCancelResult, getClientConnection, getConnectionID, getErrorMessage, getMaskedErrorMessage, getMaskedResultCode, getMatchedDN, getMessageID, getOperationID, getProcessingNanoTime, getProcessingStartTime, getProcessingStopTime, getProcessingTime, getReferralURLs, getRequestControl, getRequestControls, getResultCode, isInnerOperation, isInternalOperation, isSynchronizationOperation, operationCompleted, registerPostResponseCallback, removeAttachment, setAttachment, setAttachments, setAuthorizationEntry, setDontSynchronize, setErrorMessage, setInnerOperation, setInternalOperation, setMaskedErrorMessage, setMaskedResultCode, setMatchedDN, setReferralURLs, setResponseData, setResultCode, setSynchronizationOperation, toStringgetAdditionalLogItems, getAuthorizationDN, getErrorMessage, getMatchedDN, getProcessingStopTime, getProcessingTime, getReferralURLs, getResultCodecheckIfCanceled, disconnectClient, getAttachment, getAttachments, getClientConnection, getConnectionID, getMessageID, getOperationID, getProcessingStartTime, getRequestControl, getRequestControls, isInternalOperation, isSynchronizationOperation, removeAttachment, setAttachment, toStringpublic AddOperationBasis(ClientConnection clientConnection, long operationID, int messageID, List<Control> requestControls, org.forgerock.opendj.ldap.ByteString rawEntryDN, List<RawAttribute> rawAttributes)
clientConnection - The client connection with which this operation
is associated.operationID - The operation ID for this operation.messageID - The message ID of the request with which this
operation is associated.requestControls - The set of controls included in the request.rawEntryDN - The raw DN of the entry to add from the client
request. This may or may not be a valid DN.rawAttributes - The raw set of attributes from the client
request (including the objectclass attribute).
This may contain invalid attributes.public AddOperationBasis(ClientConnection clientConnection, long operationID, int messageID, List<Control> requestControls, DN entryDN, Map<ObjectClass,String> objectClasses, Map<AttributeType,List<Attribute>> userAttributes, Map<AttributeType,List<Attribute>> operationalAttributes)
clientConnection - The client connection with which this
operation is associated.operationID - The operation ID for this operation.messageID - The message ID of the request with which
this operation is associated.requestControls - The set of controls included in the request.entryDN - The DN for the entry.objectClasses - The set of objectclasses for the entry.userAttributes - The set of user attributes for the entry.operationalAttributes - The set of operational attributes for the
entry.public final org.forgerock.opendj.ldap.ByteString getRawEntryDN()
PreParseAddOperationgetRawEntryDN in interface AddOperationgetRawEntryDN in interface PostResponseAddOperationgetRawEntryDN in interface PreParseAddOperationpublic final void setRawEntryDN(org.forgerock.opendj.ldap.ByteString rawEntryDN)
PreParseAddOperationsetRawEntryDN in interface AddOperationsetRawEntryDN in interface PreParseAddOperationrawEntryDN - The raw entry DN for the entry to add.public final DN getEntryDN()
AddOperationgetEntryDN in interface AddOperationgetEntryDN in interface PostResponseAddOperationnull if it has not yet
been parsed from the raw DN.public final List<RawAttribute> getRawAttributes()
PreParseAddOperationgetRawAttributes in interface AddOperationgetRawAttributes in interface PostResponseAddOperationgetRawAttributes in interface PreParseAddOperationpublic final void addRawAttribute(RawAttribute rawAttribute)
PreParseAddOperationaddRawAttribute in interface AddOperationaddRawAttribute in interface PreParseAddOperationrawAttribute - The attribute to add to the set of raw
attributes for this add operation.public final void setRawAttributes(List<RawAttribute> rawAttributes)
PreParseAddOperationsetRawAttributes in interface AddOperationsetRawAttributes in interface PreParseAddOperationrawAttributes - The set of raw attributes for this add
operation.public final Map<ObjectClass,String> getObjectClasses()
AddOperationgetObjectClasses in interface AddOperationgetObjectClasses in interface PostResponseAddOperationnull if that information is not yet available.public final void addObjectClass(ObjectClass objectClass, String name)
AddOperationaddObjectClass in interface AddOperationobjectClass - The objectclass to add to the entry.name - The name to use for the objectclass.public final void removeObjectClass(ObjectClass objectClass)
AddOperationremoveObjectClass in interface AddOperationobjectClass - The objectclass to remove from the entry.public final Map<AttributeType,List<Attribute>> getUserAttributes()
AddOperationgetUserAttributes in interface AddOperationgetUserAttributes in interface PostResponseAddOperationnull if that information is not yet available.public final Map<AttributeType,List<Attribute>> getOperationalAttributes()
AddOperationgetOperationalAttributes in interface AddOperationgetOperationalAttributes in interface PostResponseAddOperationnull if that information is not yet available.public final void setAttribute(AttributeType attributeType, List<Attribute> attributeList)
AddOperationsetAttribute in interface AddOperationattributeType - The attribute type for the attribute.attributeList - The attribute list for the provided attribute type.public final void removeAttribute(AttributeType attributeType)
AddOperationremoveAttribute in interface AddOperationattributeType - The attribute tyep for the attribute to remove.public final OperationType getOperationType()
PluginOperationgetOperationType in interface OperationgetOperationType in interface PluginOperationpublic DN getProxiedAuthorizationDN()
AddOperationgetProxiedAuthorizationDN in interface AddOperationgetProxiedAuthorizationDN in interface Operationnull if proxied
authorization has not been requested.public final ArrayList<Control> getResponseControls()
PluginOperationgetResponseControls in interface OperationgetResponseControls in interface PluginOperationpublic final void addResponseControl(Control control)
PreParseOperationaddResponseControl in interface OperationaddResponseControl in interface PreParseOperationcontrol - The control to add to the set of controls to
include in the response to the client.public final void removeResponseControl(Control control)
PreParseOperationremoveResponseControl in interface OperationremoveResponseControl in interface PreParseOperationcontrol - The control to remove from the set of controls
to include in the response to the client.public final void toString(StringBuilder buffer)
PluginOperationtoString in interface OperationtoString in interface PluginOperationbuffer - The buffer into which a string representation of
this operation should be appended.public void setProxiedAuthorizationDN(DN proxiedAuthorizationDN)
AddOperationsetProxiedAuthorizationDN in interface AddOperationsetProxiedAuthorizationDN in interface OperationproxiedAuthorizationDN - The proxied authorization DN for this operation if proxied
authorization has been requested, or null if proxied
authorization has not been requested.public final void run()
Operationpublic void updateOperationErrMsgAndResCode()
AbstractOperationupdateOperationErrMsgAndResCode in class AbstractOperationpublic Entry getEntryToAdd()
getEntryToAdd in interface PostResponseAddOperationCopyright © 2010-2015 ForgeRock AS. All Rights Reserved.