Record Class UpdateRecord
java.lang.Object
java.lang.Record
org.opends.server.replication.server.changelog.api.UpdateRecord
- Record Components:
baseDn- the base DN of the replication domain the message belongs toupdateMsg- the update message
- All Implemented Interfaces:
Comparable<UpdateRecord>
public record UpdateRecord(Dn baseDn, UpdateMsg updateMsg)
extends Record
implements Comparable<UpdateRecord>
Represents an update message with the base DN of the replication domain it belongs to, with support for easy
retrieval of the CSN and the replica ID corresponding to the message.
-
Constructor Summary
ConstructorsConstructorDescriptionUpdateRecord(Dn baseDn, UpdateMsg updateMsg) Creates an instance of aUpdateRecordrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbaseDn()Returns the value of thebaseDnrecord component.intcompareTo(UpdateRecord other) booleanIndicates whether some other object is "equal to" this one.getCsn()Returns the CSN of the message.Returns the replica ID of the replica the message belongs to.inthashCode()Returns a hash code value for this object.static UpdateRecordnewUpdateRecord(Dn baseDn, UpdateMsg msg) Creates a new update record with the provided base DN and message.toString()Returns a string representation of this record class.Returns the value of theupdateMsgrecord component.
-
Constructor Details
-
Method Details
-
newUpdateRecord
Creates a new update record with the provided base DN and message.- Parameters:
baseDn- the base DN of the replication domain the message belongs tomsg- the update message- Returns:
- a new update record with the provided base DN and message.
-
getCsn
Returns the CSN of the message.- Returns:
- the CSN of the message
-
getReplicaId
Returns the replica ID of the replica the message belongs to.- Returns:
- the replica ID of the replica the message belongs to
-
hashCode
public int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
compareTo
- Specified by:
compareToin interfaceComparable<UpdateRecord>
-
baseDn
Returns the value of thebaseDnrecord component.- Returns:
- the value of the
baseDnrecord component
-
updateMsg
Returns the value of theupdateMsgrecord component.- Returns:
- the value of the
updateMsgrecord component
-