Record Class CJ1Transaction
java.lang.Object
java.lang.Record
com.io7m.cardant.protocol.inventory.json.internal.CJ1Transaction
- All Implemented Interfaces:
CJ1MessageType, CJ1ValueType
@JsonClassDescription("A set of commands to execute in a single transaction.")
public record CJ1Transaction(List<CJ1CommandType> commands)
extends Record
implements CJ1MessageType
-
Constructor Summary
ConstructorsConstructorDescriptionCJ1Transaction(List<CJ1CommandType> commands) Creates an instance of aCJ1Transactionrecord class. -
Method Summary
Modifier and TypeMethodDescriptioncommands()Returns the value of thecommandsrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
CJ1Transaction
public CJ1Transaction(@JsonPropertyDescription("The commands that will be executed in the given order.") List<CJ1CommandType> commands) Creates an instance of aCJ1Transactionrecord class.- Parameters:
commands- the value for thecommandsrecord component
-
-
Method Details
-
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). -
commands
@JsonPropertyDescription("The commands that will be executed in the given order.") public List<CJ1CommandType> commands()Returns the value of thecommandsrecord component.- Returns:
- the value of the
commandsrecord component
-