java.lang.Object
java.lang.Record
it.auties.whatsapp.model.info.AdReplyInfo
- All Implemented Interfaces:
it.auties.protobuf.model.ProtobufMessage
,it.auties.protobuf.model.ProtobufObject
,Info
public record AdReplyInfo(String advertiserName, AdReplyInfo.MediaType mediaType, Optional<byte[]> thumbnail, Optional<String> caption)
extends Record
implements Info, it.auties.protobuf.model.ProtobufMessage
A model class that holds the information related to an companion reply.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enum
The constants of this enumerated type describe the various types of companion that aAdReplyInfo
can link to -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final String
The field for theadvertiserName
record component.The field for thecaption
record component.private final AdReplyInfo.MediaType
The field for themediaType
record component.private final Optional
<byte[]> The field for thethumbnail
record component. -
Constructor Summary
ConstructorsConstructorDescriptionAdReplyInfo
(String advertiserName, AdReplyInfo.MediaType mediaType, Optional<byte[]> thumbnail, Optional<String> caption) Creates an instance of aAdReplyInfo
record class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theadvertiserName
record component.caption()
Returns the value of thecaption
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.Returns the value of themediaType
record component.Optional
<byte[]> Returns the value of thethumbnail
record component.final String
toString()
Returns a string representation of this record class.
-
Field Details
-
advertiserName
The field for theadvertiserName
record component. -
mediaType
The field for themediaType
record component. -
thumbnail
The field for thethumbnail
record component. -
caption
The field for thecaption
record component.
-
-
Constructor Details
-
AdReplyInfo
public AdReplyInfo(String advertiserName, AdReplyInfo.MediaType mediaType, Optional<byte[]> thumbnail, Optional<String> caption) Creates an instance of aAdReplyInfo
record class.- Parameters:
advertiserName
- the value for theadvertiserName
record componentmediaType
- the value for themediaType
record componentthumbnail
- the value for thethumbnail
record componentcaption
- the value for thecaption
record 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)
. -
advertiserName
Returns the value of theadvertiserName
record component.- Returns:
- the value of the
advertiserName
record component
-
mediaType
Returns the value of themediaType
record component.- Returns:
- the value of the
mediaType
record component
-
thumbnail
Returns the value of thethumbnail
record component.- Returns:
- the value of the
thumbnail
record component
-
caption
Returns the value of thecaption
record component.- Returns:
- the value of the
caption
record component
-