Record Class EvmXmlRenderer.StateWitness
java.lang.Object
java.lang.Record
net.finmath.smartcontracts.representablestate.xml.EvmXmlRenderer.StateWitness
- Record Components:
stateVersion- Monotonic represented-state version.stateHash- Optional canonical represented-state hash.
- Enclosing class:
EvmXmlRenderer
public static record EvmXmlRenderer.StateWitness(BigInteger stateVersion, Optional<String> stateHash)
extends Record
Optional cross-block state identity advertised by a representable-state
contract.
-
Constructor Summary
ConstructorsConstructorDescriptionStateWitness(BigInteger stateVersion, Optional<String> stateHash) Creates an instance of aStateWitnessrecord class. -
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.Returns the value of thestateHashrecord component.Returns the value of thestateVersionrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
StateWitness
Creates an instance of aStateWitnessrecord class.- Parameters:
stateVersion- the value for thestateVersionrecord componentstateHash- the value for thestateHashrecord component
-
-
Method Details
-
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. -
hashCode
public final 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). -
stateVersion
Returns the value of thestateVersionrecord component.- Returns:
- the value of the
stateVersionrecord component
-
stateHash
Returns the value of thestateHashrecord component.- Returns:
- the value of the
stateHashrecord component
-