Record Class CAI1ItemSerial
java.lang.Object
java.lang.Record
com.io7m.cardant.protocol.inventory.cb.CAI1ItemSerial
- Record Components:
fieldType-fieldValue-
- All Implemented Interfaces:
com.io7m.cedarbridge.runtime.api.CBSerializableType
public record CAI1ItemSerial(com.io7m.cedarbridge.runtime.api.CBString fieldType, com.io7m.cedarbridge.runtime.api.CBString fieldValue)
extends Record
implements com.io7m.cedarbridge.runtime.api.CBSerializableType
A serial number.
-
Constructor Summary
ConstructorsConstructorDescriptionCAI1ItemSerial(com.io7m.cedarbridge.runtime.api.CBString fieldType, com.io7m.cedarbridge.runtime.api.CBString fieldValue) Creates an instance of aCAI1ItemSerialrecord class. -
Method Summary
Modifier and TypeMethodDescriptionstatic CAI1ItemSerialdeserialize(com.io7m.cedarbridge.runtime.api.CBSerializationContextType $context) Deserialize a value of type CAI1ItemSerial.final booleanIndicates whether some other object is "equal to" this one.com.io7m.cedarbridge.runtime.api.CBStringReturns the value of thefieldTyperecord component.com.io7m.cedarbridge.runtime.api.CBStringReturns the value of thefieldValuerecord component.final inthashCode()Returns a hash code value for this object.static voidserialize(com.io7m.cedarbridge.runtime.api.CBSerializationContextType $context, CAI1ItemSerial $x) Serialize a value of type CAI1ItemSerial.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
CAI1ItemSerial
public CAI1ItemSerial(com.io7m.cedarbridge.runtime.api.CBString fieldType, com.io7m.cedarbridge.runtime.api.CBString fieldValue) Creates an instance of aCAI1ItemSerialrecord class.- Parameters:
fieldType- the value for thefieldTyperecord componentfieldValue- the value for thefieldValuerecord component
-
-
Method Details
-
serialize
public static void serialize(com.io7m.cedarbridge.runtime.api.CBSerializationContextType $context, CAI1ItemSerial $x) throws IOException Serialize a value of type CAI1ItemSerial.- Parameters:
$context- The serialization context.$x- The value to be serialized.- Throws:
IOException
-
deserialize
public static CAI1ItemSerial deserialize(com.io7m.cedarbridge.runtime.api.CBSerializationContextType $context) throws IOException Deserialize a value of type CAI1ItemSerial.- Parameters:
$context- The serialization context.- Returns:
- A value of type CAI1ItemSerial.
- Throws:
IOException
-
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). -
fieldType
-
fieldValue
public com.io7m.cedarbridge.runtime.api.CBString fieldValue()Returns the value of thefieldValuerecord component.- Returns:
- the value of the
fieldValuerecord component
-