Record Class ConsensusSnapshot
java.lang.Object
java.lang.Record
org.j7m.middleware.api.consensus.ConsensusSnapshot
- Record Components:
metadata- snapshot metadatapayload- snapshot bytes
- All Implemented Interfaces:
Serializable
public record ConsensusSnapshot(ConsensusSnapshotMetadata metadata, byte[] payload)
extends Record
implements Serializable
Snapshot payload container for future snapshot installation support.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionConsensusSnapshot(ConsensusSnapshotMetadata metadata, byte[] payload) Creates a snapshot. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.metadata()Returns the value of themetadatarecord component.byte[]payload()Returns a defensive copy of snapshot payload bytes.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ConsensusSnapshot
Creates a snapshot.
-
-
Method Details
-
payload
public byte[] payload()Returns a defensive copy of snapshot payload bytes.- Returns:
- snapshot payload copy
-
toString
-
hashCode
-
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). -
metadata
-