Module it.auties.cobalt
Record Class HydratedURLButton
java.lang.Object
java.lang.Record
it.auties.whatsapp.model.button.template.hydrated.HydratedURLButton
- All Implemented Interfaces:
it.auties.protobuf.model.ProtobufMessage
,it.auties.protobuf.model.ProtobufObject
,HydratedButton
A model class that represents a hydrated url button
-
Nested Class Summary
Nested classes/interfaces inherited from interface it.auties.whatsapp.model.button.template.hydrated.HydratedButton
HydratedButton.Type
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionHydratedURLButton
(String text, String url) Creates an instance of aHydratedURLButton
record class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the type of this buttonfinal boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.text()
Returns the value of thetext
record component.final String
toString()
Returns a string representation of this record class.url()
Returns the value of theurl
record component.
-
Field Details
-
text
The field for thetext
record component. -
url
The field for theurl
record component.
-
-
Constructor Details
-
HydratedURLButton
Creates an instance of aHydratedURLButton
record class.- Parameters:
text
- the value for thetext
record componenturl
- the value for theurl
record component
-
-
Method Details
-
buttonType
Description copied from interface:HydratedButton
Returns the type of this button- Specified by:
buttonType
in interfaceHydratedButton
- Returns:
- a non-null type
-
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)
. -
text
Returns the value of thetext
record component.- Specified by:
text
in interfaceHydratedButton
- Returns:
- the value of the
text
record component
-
url
Returns the value of theurl
record component.- Returns:
- the value of the
url
record component
-