java.lang.Object
java.lang.Record
it.auties.whatsapp.model.info.ExternalAdReplyInfo
- All Implemented Interfaces:
it.auties.protobuf.model.ProtobufMessage,it.auties.protobuf.model.ProtobufObject,Info
public record ExternalAdReplyInfo(Optional<String> title, Optional<String> body, Optional<ExternalAdReplyInfo.MediaType> mediaType, Optional<String> thumbnailUrl, Optional<String> mediaUrl, Optional<byte[]> thumbnail, Optional<String> sourceType, Optional<String> sourceId, Optional<String> sourceUrl, boolean containsAutoReply, boolean renderLargerThumbnail, boolean showAdAttribution, Optional<String> ctwaClid)
extends Record
implements Info, it.auties.protobuf.model.ProtobufMessage
A model class that holds the information related to an advertisement.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumThe constants of this enumerated type describe the various types of media that an ad can wrap -
Field Summary
FieldsModifier and TypeFieldDescriptionThe field for thebodyrecord component.private final booleanThe field for thecontainsAutoReplyrecord component.The field for thectwaClidrecord component.private final Optional<ExternalAdReplyInfo.MediaType> The field for themediaTyperecord component.The field for themediaUrlrecord component.private final booleanThe field for therenderLargerThumbnailrecord component.private final booleanThe field for theshowAdAttributionrecord component.The field for thesourceIdrecord component.The field for thesourceTyperecord component.The field for thesourceUrlrecord component.private final Optional<byte[]> The field for thethumbnailrecord component.The field for thethumbnailUrlrecord component.The field for thetitlerecord component. -
Constructor Summary
ConstructorsConstructorDescriptionExternalAdReplyInfo(Optional<String> title, Optional<String> body, Optional<ExternalAdReplyInfo.MediaType> mediaType, Optional<String> thumbnailUrl, Optional<String> mediaUrl, Optional<byte[]> thumbnail, Optional<String> sourceType, Optional<String> sourceId, Optional<String> sourceUrl, boolean containsAutoReply, boolean renderLargerThumbnail, boolean showAdAttribution, Optional<String> ctwaClid) Creates an instance of aExternalAdReplyInforecord class. -
Method Summary
Modifier and TypeMethodDescriptionbody()Returns the value of thebodyrecord component.booleanReturns the value of thecontainsAutoReplyrecord component.ctwaClid()Returns the value of thectwaClidrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of themediaTyperecord component.mediaUrl()Returns the value of themediaUrlrecord component.booleanReturns the value of therenderLargerThumbnailrecord component.booleanReturns the value of theshowAdAttributionrecord component.sourceId()Returns the value of thesourceIdrecord component.Returns the value of thesourceTyperecord component.Returns the value of thesourceUrlrecord component.Optional<byte[]> Returns the value of thethumbnailrecord component.Returns the value of thethumbnailUrlrecord component.title()Returns the value of thetitlerecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
title
The field for thetitlerecord component. -
body
The field for thebodyrecord component. -
mediaType
The field for themediaTyperecord component. -
thumbnailUrl
The field for thethumbnailUrlrecord component. -
mediaUrl
The field for themediaUrlrecord component. -
thumbnail
The field for thethumbnailrecord component. -
sourceType
The field for thesourceTyperecord component. -
sourceId
The field for thesourceIdrecord component. -
sourceUrl
The field for thesourceUrlrecord component. -
containsAutoReply
private final boolean containsAutoReplyThe field for thecontainsAutoReplyrecord component. -
renderLargerThumbnail
private final boolean renderLargerThumbnailThe field for therenderLargerThumbnailrecord component. -
showAdAttribution
private final boolean showAdAttributionThe field for theshowAdAttributionrecord component. -
ctwaClid
The field for thectwaClidrecord component.
-
-
Constructor Details
-
ExternalAdReplyInfo
public ExternalAdReplyInfo(Optional<String> title, Optional<String> body, Optional<ExternalAdReplyInfo.MediaType> mediaType, Optional<String> thumbnailUrl, Optional<String> mediaUrl, Optional<byte[]> thumbnail, Optional<String> sourceType, Optional<String> sourceId, Optional<String> sourceUrl, boolean containsAutoReply, boolean renderLargerThumbnail, boolean showAdAttribution, Optional<String> ctwaClid) Creates an instance of aExternalAdReplyInforecord class.- Parameters:
title- the value for thetitlerecord componentbody- the value for thebodyrecord componentmediaType- the value for themediaTyperecord componentthumbnailUrl- the value for thethumbnailUrlrecord componentmediaUrl- the value for themediaUrlrecord componentthumbnail- the value for thethumbnailrecord componentsourceType- the value for thesourceTyperecord componentsourceId- the value for thesourceIdrecord componentsourceUrl- the value for thesourceUrlrecord componentcontainsAutoReply- the value for thecontainsAutoReplyrecord componentrenderLargerThumbnail- the value for therenderLargerThumbnailrecord componentshowAdAttribution- the value for theshowAdAttributionrecord componentctwaClid- the value for thectwaClidrecord 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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
title
Returns the value of thetitlerecord component.- Returns:
- the value of the
titlerecord component
-
body
Returns the value of thebodyrecord component.- Returns:
- the value of the
bodyrecord component
-
mediaType
Returns the value of themediaTyperecord component.- Returns:
- the value of the
mediaTyperecord component
-
thumbnailUrl
Returns the value of thethumbnailUrlrecord component.- Returns:
- the value of the
thumbnailUrlrecord component
-
mediaUrl
Returns the value of themediaUrlrecord component.- Returns:
- the value of the
mediaUrlrecord component
-
thumbnail
Returns the value of thethumbnailrecord component.- Returns:
- the value of the
thumbnailrecord component
-
sourceType
Returns the value of thesourceTyperecord component.- Returns:
- the value of the
sourceTyperecord component
-
sourceId
Returns the value of thesourceIdrecord component.- Returns:
- the value of the
sourceIdrecord component
-
sourceUrl
Returns the value of thesourceUrlrecord component.- Returns:
- the value of the
sourceUrlrecord component
-
containsAutoReply
public boolean containsAutoReply()Returns the value of thecontainsAutoReplyrecord component.- Returns:
- the value of the
containsAutoReplyrecord component
-
renderLargerThumbnail
public boolean renderLargerThumbnail()Returns the value of therenderLargerThumbnailrecord component.- Returns:
- the value of the
renderLargerThumbnailrecord component
-
showAdAttribution
public boolean showAdAttribution()Returns the value of theshowAdAttributionrecord component.- Returns:
- the value of the
showAdAttributionrecord component
-
ctwaClid
Returns the value of thectwaClidrecord component.- Returns:
- the value of the
ctwaClidrecord component
-