Record Class GiveawayWinners
java.lang.Object
java.lang.Record
org.teleight.teleightbots.api.objects.GiveawayWinners
- All Implemented Interfaces:
Serializable,ApiResult
public record GiveawayWinners(@NotNull Chat chat, int giveawayMessageId, @NotNull Date winnersSelectionDate, int winnerCount, @NotNull User[] winners, int additionalChatCount, int prizeStarCount, int premiumSubscriptionMonthCount, int unclaimedPrizeCount, boolean onlyNewMembers, boolean wasRefunded, @Nullable String prizeDescription)
extends Record
implements ApiResult
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionGiveawayWinners(@NotNull Chat chat, int giveawayMessageId, @NotNull Date winnersSelectionDate, int winnerCount, @NotNull User[] winners, int additionalChatCount, int prizeStarCount, int premiumSubscriptionMonthCount, int unclaimedPrizeCount, boolean onlyNewMembers, boolean wasRefunded, @Nullable String prizeDescription) Creates an instance of aGiveawayWinnersrecord class. -
Method Summary
Modifier and TypeMethodDescriptionintReturns the value of theadditionalChatCountrecord component.@NotNull Chatchat()Returns the value of thechatrecord component.final booleanIndicates whether some other object is "equal to" this one.intReturns the value of thegiveawayMessageIdrecord component.final inthashCode()Returns a hash code value for this object.booleanReturns the value of theonlyNewMembersrecord component.intReturns the value of thepremiumSubscriptionMonthCountrecord component.@Nullable StringReturns the value of theprizeDescriptionrecord component.intReturns the value of theprizeStarCountrecord component.final StringtoString()Returns a string representation of this record class.intReturns the value of theunclaimedPrizeCountrecord component.booleanReturns the value of thewasRefundedrecord component.intReturns the value of thewinnerCountrecord component.@NotNull User[]winners()Returns the value of thewinnersrecord component.@NotNull DateReturns the value of thewinnersSelectionDaterecord component.
-
Constructor Details
-
GiveawayWinners
public GiveawayWinners(@NotNull @NotNull Chat chat, int giveawayMessageId, @NotNull @NotNull Date winnersSelectionDate, int winnerCount, @NotNull @NotNull User[] winners, int additionalChatCount, int prizeStarCount, int premiumSubscriptionMonthCount, int unclaimedPrizeCount, boolean onlyNewMembers, boolean wasRefunded, @Nullable @Nullable String prizeDescription) Creates an instance of aGiveawayWinnersrecord class.- Parameters:
chat- the value for thechatrecord componentgiveawayMessageId- the value for thegiveawayMessageIdrecord componentwinnersSelectionDate- the value for thewinnersSelectionDaterecord componentwinnerCount- the value for thewinnerCountrecord componentwinners- the value for thewinnersrecord componentadditionalChatCount- the value for theadditionalChatCountrecord componentprizeStarCount- the value for theprizeStarCountrecord componentpremiumSubscriptionMonthCount- the value for thepremiumSubscriptionMonthCountrecord componentunclaimedPrizeCount- the value for theunclaimedPrizeCountrecord componentonlyNewMembers- the value for theonlyNewMembersrecord componentwasRefunded- the value for thewasRefundedrecord componentprizeDescription- the value for theprizeDescriptionrecord 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 '=='. -
chat
Returns the value of thechatrecord component.- Returns:
- the value of the
chatrecord component
-
giveawayMessageId
public int giveawayMessageId()Returns the value of thegiveawayMessageIdrecord component.- Returns:
- the value of the
giveawayMessageIdrecord component
-
winnersSelectionDate
Returns the value of thewinnersSelectionDaterecord component.- Returns:
- the value of the
winnersSelectionDaterecord component
-
winnerCount
public int winnerCount()Returns the value of thewinnerCountrecord component.- Returns:
- the value of the
winnerCountrecord component
-
winners
Returns the value of thewinnersrecord component.- Returns:
- the value of the
winnersrecord component
-
additionalChatCount
public int additionalChatCount()Returns the value of theadditionalChatCountrecord component.- Returns:
- the value of the
additionalChatCountrecord component
-
prizeStarCount
public int prizeStarCount()Returns the value of theprizeStarCountrecord component.- Returns:
- the value of the
prizeStarCountrecord component
-
unclaimedPrizeCount
public int unclaimedPrizeCount()Returns the value of theunclaimedPrizeCountrecord component.- Returns:
- the value of the
unclaimedPrizeCountrecord component
-
onlyNewMembers
public boolean onlyNewMembers()Returns the value of theonlyNewMembersrecord component.- Returns:
- the value of the
onlyNewMembersrecord component
-
wasRefunded
public boolean wasRefunded()Returns the value of thewasRefundedrecord component.- Returns:
- the value of the
wasRefundedrecord component
-
prizeDescription
Returns the value of theprizeDescriptionrecord component.- Returns:
- the value of the
prizeDescriptionrecord component
-