|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.opends.server.replication.protocol.ReplicationMessage
org.opends.server.replication.protocol.UpdateMessage
org.opends.server.replication.protocol.AddMsg
public class AddMsg
This class is used to exchange Add operation between LDAP servers and replication servers.
| Constructor Summary | |
|---|---|
AddMsg(byte[] in)
Creates a new Add message from a byte[]. |
|
AddMsg(ChangeNumber cn,
java.lang.String dn,
java.lang.String uniqueId,
java.lang.String parentId,
Attribute objectClass,
java.util.Collection<Attribute> userAttributes,
java.util.Collection<Attribute> operationalAttributes)
Creates a new AddMessage. |
|
AddMsg(PostOperationAddOperation op)
Creates a new AddMessage. |
|
| Method Summary | |
|---|---|
void |
addAttribute(java.lang.String name,
java.lang.String value)
Add the specified attribute/attribute value in the entry contained in this AddMsg. |
AbstractOperation |
createOperation(InternalClientConnection connection,
java.lang.String newDn)
Create and Operation from the message using the provided DN. |
byte[] |
getBytes()
Get the byte[] representation of this Message. |
java.lang.String |
getParentUid()
Get the parent unique id of this add msg. |
void |
setParentUid(java.lang.String uid)
Set the parent unique id of this add msg. |
java.lang.String |
toString()
|
| Methods inherited from class org.opends.server.replication.protocol.UpdateMessage |
|---|
compareTo, createOperation, decodeHeader, encodeHeader, equals, generateMsg, getChangeNumber, getDn, getUniqueId, hashCode, isAssured, setAssured, setDn |
| Methods inherited from class org.opends.server.replication.protocol.ReplicationMessage |
|---|
addByteArray, generateMsg, getNextLength |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public AddMsg(PostOperationAddOperation op)
op - the operation to use when creating the message
public AddMsg(ChangeNumber cn,
java.lang.String dn,
java.lang.String uniqueId,
java.lang.String parentId,
Attribute objectClass,
java.util.Collection<Attribute> userAttributes,
java.util.Collection<Attribute> operationalAttributes)
cn - ChangeNumber of the add.dn - DN of the added entry.uniqueId - The Unique identifier of the added entry.parentId - The unique Id of the parent of the added entry.objectClass - objectclass of the added entry.userAttributes - user attributes of the added entry.operationalAttributes - operational attributes of the added entry.
public AddMsg(byte[] in)
throws java.util.zip.DataFormatException,
java.io.UnsupportedEncodingException
in - The byte[] from which the operation must be read.
java.util.zip.DataFormatException - The input byte[] is not a valid AddMsg
java.io.UnsupportedEncodingException - If UTF8 is not supported by the jvm| Method Detail |
|---|
public AbstractOperation createOperation(InternalClientConnection connection,
java.lang.String newDn)
throws LDAPException,
ASN1Exception
createOperation in class UpdateMessageconnection - connection to use when creating the message.newDn - the DN to use when creating the operation.
LDAPException - In case of LDAP decoding exception.
ASN1Exception - In case of ASN1 decoding exception.
public byte[] getBytes()
throws java.io.UnsupportedEncodingException
getBytes in class ReplicationMessagejava.io.UnsupportedEncodingException - When the encoding of the message
failed because the UTF-8 encoding is not supported.public java.lang.String toString()
toString in class java.lang.Object
public void addAttribute(java.lang.String name,
java.lang.String value)
throws ASN1Exception
name - The name of the attribute to add.value - The value of the attribute to add.
ASN1Exception - When this Msg is not valid.public void setParentUid(java.lang.String uid)
uid - the parent unique id.public java.lang.String getParentUid()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||