Record Class CJ1AttachmentItem
java.lang.Object
java.lang.Record
com.io7m.cardant.protocol.inventory.json.internal.CJ1AttachmentItem
- All Implemented Interfaces:
CJ1ValueType
@JsonClassDescription("An attachment.")
public record CJ1AttachmentItem(CJ1AttachmentKey key, CJ1Attachment attachment)
extends Record
implements CJ1ValueType
-
Constructor Summary
ConstructorsConstructorDescriptionCJ1AttachmentItem(CJ1AttachmentKey key, CJ1Attachment attachment) Creates an instance of aCJ1AttachmentItemrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theattachmentrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.key()Returns the value of thekeyrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
CJ1AttachmentItem
public CJ1AttachmentItem(@JsonPropertyDescription("The attachment key.") CJ1AttachmentKey key, @JsonPropertyDescription("The attachment.") CJ1Attachment attachment) Creates an instance of aCJ1AttachmentItemrecord class.- Parameters:
key- the value for thekeyrecord componentattachment- the value for theattachmentrecord 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). -
key
Returns the value of thekeyrecord component.- Returns:
- the value of the
keyrecord component
-
attachment
Returns the value of theattachmentrecord component.- Returns:
- the value of the
attachmentrecord component
-