Record Class PollAnswer
java.lang.Object
java.lang.Record
org.teleight.teleightbots.api.objects.PollAnswer
- All Implemented Interfaces:
Serializable, ApiResult
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription@Nullable Chatchat()Returns the value of thechatrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Integer[]Returns the value of theoptionIdsrecord component.String[]Returns the value of theoptionPersistentIdsrecord component.pollId()Returns the value of thepollIdrecord component.final StringtoString()Returns a string representation of this record class.@Nullable Useruser()Returns the value of theuserrecord component.
-
Constructor Details
-
PollAnswer
public PollAnswer(String pollId, @Nullable @Nullable Chat chat, @Nullable @Nullable User user, Integer[] optionIds, String[] optionPersistentIds) Creates an instance of aPollAnswerrecord class.- Parameters:
pollId- the value for thepollIdrecord componentchat- the value for thechatrecord componentuser- the value for theuserrecord componentoptionIds- the value for theoptionIdsrecord componentoptionPersistentIds- the value for theoptionPersistentIdsrecord 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). -
pollId
Returns the value of thepollIdrecord component.- Returns:
- the value of the
pollIdrecord component
-
chat
Returns the value of thechatrecord component.- Returns:
- the value of the
chatrecord component
-
user
Returns the value of theuserrecord component.- Returns:
- the value of the
userrecord component
-
optionIds
Returns the value of theoptionIdsrecord component.- Returns:
- the value of the
optionIdsrecord component
-
optionPersistentIds
Returns the value of theoptionPersistentIdsrecord component.- Returns:
- the value of the
optionPersistentIdsrecord component
-