Record Class CAI1File.CAI1FileWithData
java.lang.Object
java.lang.Record
com.io7m.cardant.protocol.inventory.cb.CAI1File.CAI1FileWithData
- Record Components:
fieldId- The file ID.fieldDescription- The file description.fieldMediaType- The media type.fieldSize- The file size.fieldHashAlgorithm- The hash algorithm name.fieldHashValue- The hash value.fieldData- The file data.
- All Implemented Interfaces:
CAI1File,com.io7m.cedarbridge.runtime.api.CBSerializableType
- Enclosing interface:
CAI1File
public static record CAI1File.CAI1FileWithData(com.io7m.cedarbridge.runtime.api.CBUUID fieldId, com.io7m.cedarbridge.runtime.api.CBString fieldDescription, com.io7m.cedarbridge.runtime.api.CBString fieldMediaType, com.io7m.cedarbridge.runtime.api.CBIntegerUnsigned64 fieldSize, com.io7m.cedarbridge.runtime.api.CBString fieldHashAlgorithm, com.io7m.cedarbridge.runtime.api.CBString fieldHashValue, com.io7m.cedarbridge.runtime.api.CBByteArray fieldData)
extends Record
implements com.io7m.cedarbridge.runtime.api.CBSerializableType, CAI1File
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.io7m.cardant.protocol.inventory.cb.CAI1File
CAI1File.CAI1FileWithData, CAI1File.CAI1FileWithoutData -
Constructor Summary
ConstructorsConstructorDescriptionCAI1FileWithData(com.io7m.cedarbridge.runtime.api.CBUUID fieldId, com.io7m.cedarbridge.runtime.api.CBString fieldDescription, com.io7m.cedarbridge.runtime.api.CBString fieldMediaType, com.io7m.cedarbridge.runtime.api.CBIntegerUnsigned64 fieldSize, com.io7m.cedarbridge.runtime.api.CBString fieldHashAlgorithm, com.io7m.cedarbridge.runtime.api.CBString fieldHashValue, com.io7m.cedarbridge.runtime.api.CBByteArray fieldData) Creates an instance of aCAI1FileWithDatarecord class. -
Method Summary
Modifier and TypeMethodDescriptionstatic CAI1File.CAI1FileWithDatadeserialize(com.io7m.cedarbridge.runtime.api.CBSerializationContextType $context) Deserialize a value of type com.io7m.cardant.protocol.inventory.cb.CAI1FileWithData.final booleanIndicates whether some other object is "equal to" this one.com.io7m.cedarbridge.runtime.api.CBByteArrayReturns the value of thefieldDatarecord component.com.io7m.cedarbridge.runtime.api.CBStringReturns the value of thefieldDescriptionrecord component.com.io7m.cedarbridge.runtime.api.CBStringReturns the value of thefieldHashAlgorithmrecord component.com.io7m.cedarbridge.runtime.api.CBStringReturns the value of thefieldHashValuerecord component.com.io7m.cedarbridge.runtime.api.CBUUIDfieldId()Returns the value of thefieldIdrecord component.com.io7m.cedarbridge.runtime.api.CBStringReturns the value of thefieldMediaTyperecord component.com.io7m.cedarbridge.runtime.api.CBIntegerUnsigned64Returns the value of thefieldSizerecord component.final inthashCode()Returns a hash code value for this object.static voidserialize(com.io7m.cedarbridge.runtime.api.CBSerializationContextType $context, CAI1File.CAI1FileWithData $x) Serialize a value of type com.io7m.cardant.protocol.inventory.cb.CAI1FileWithData.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
CAI1FileWithData
public CAI1FileWithData(com.io7m.cedarbridge.runtime.api.CBUUID fieldId, com.io7m.cedarbridge.runtime.api.CBString fieldDescription, com.io7m.cedarbridge.runtime.api.CBString fieldMediaType, com.io7m.cedarbridge.runtime.api.CBIntegerUnsigned64 fieldSize, com.io7m.cedarbridge.runtime.api.CBString fieldHashAlgorithm, com.io7m.cedarbridge.runtime.api.CBString fieldHashValue, com.io7m.cedarbridge.runtime.api.CBByteArray fieldData) Creates an instance of aCAI1FileWithDatarecord class.- Parameters:
fieldId- the value for thefieldIdrecord componentfieldDescription- the value for thefieldDescriptionrecord componentfieldMediaType- the value for thefieldMediaTyperecord componentfieldSize- the value for thefieldSizerecord componentfieldHashAlgorithm- the value for thefieldHashAlgorithmrecord componentfieldHashValue- the value for thefieldHashValuerecord componentfieldData- the value for thefieldDatarecord component
-
-
Method Details
-
serialize
public static void serialize(com.io7m.cedarbridge.runtime.api.CBSerializationContextType $context, CAI1File.CAI1FileWithData $x) throws IOException Serialize a value of type com.io7m.cardant.protocol.inventory.cb.CAI1FileWithData.- Parameters:
$context- The serialization context.$x- The value to be serialized.- Throws:
IOException
-
deserialize
public static CAI1File.CAI1FileWithData deserialize(com.io7m.cedarbridge.runtime.api.CBSerializationContextType $context) throws IOException Deserialize a value of type com.io7m.cardant.protocol.inventory.cb.CAI1FileWithData.- Parameters:
$context- The serialization context.- Returns:
- A value of type com.io7m.cardant.protocol.inventory.cb.CAI1FileWithData.
- 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). -
fieldId
-
fieldDescription
public com.io7m.cedarbridge.runtime.api.CBString fieldDescription()Returns the value of thefieldDescriptionrecord component.- Returns:
- the value of the
fieldDescriptionrecord component
-
fieldMediaType
public com.io7m.cedarbridge.runtime.api.CBString fieldMediaType()Returns the value of thefieldMediaTyperecord component.- Returns:
- the value of the
fieldMediaTyperecord component
-
fieldSize
-
fieldHashAlgorithm
public com.io7m.cedarbridge.runtime.api.CBString fieldHashAlgorithm()Returns the value of thefieldHashAlgorithmrecord component.- Returns:
- the value of the
fieldHashAlgorithmrecord component
-
fieldHashValue
public com.io7m.cedarbridge.runtime.api.CBString fieldHashValue()Returns the value of thefieldHashValuerecord component.- Returns:
- the value of the
fieldHashValuerecord component
-
fieldData
-