Record Class GiveawayCompleted
java.lang.Object
java.lang.Record
org.teleight.teleightbots.api.objects.GiveawayCompleted
- All Implemented Interfaces:
Serializable,ApiResult
public record GiveawayCompleted(int winnerCount, int unclaimedPrizeCount, @Nullable Message giveawayMessage, boolean isStarGiveaway)
extends Record
implements ApiResult
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionGiveawayCompleted(int winnerCount, int unclaimedPrizeCount, @Nullable Message giveawayMessage, boolean isStarGiveaway) Creates an instance of aGiveawayCompletedrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.@Nullable MessageReturns the value of thegiveawayMessagerecord component.final inthashCode()Returns a hash code value for this object.booleanReturns the value of theisStarGiveawayrecord component.final StringtoString()Returns a string representation of this record class.intReturns the value of theunclaimedPrizeCountrecord component.intReturns the value of thewinnerCountrecord component.
-
Constructor Details
-
GiveawayCompleted
public GiveawayCompleted(int winnerCount, int unclaimedPrizeCount, @Nullable @Nullable Message giveawayMessage, boolean isStarGiveaway) Creates an instance of aGiveawayCompletedrecord class.- Parameters:
winnerCount- the value for thewinnerCountrecord componentunclaimedPrizeCount- the value for theunclaimedPrizeCountrecord componentgiveawayMessage- the value for thegiveawayMessagerecord componentisStarGiveaway- the value for theisStarGiveawayrecord 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 '=='. -
winnerCount
public int winnerCount()Returns the value of thewinnerCountrecord component.- Returns:
- the value of the
winnerCountrecord component
-
unclaimedPrizeCount
public int unclaimedPrizeCount()Returns the value of theunclaimedPrizeCountrecord component.- Returns:
- the value of the
unclaimedPrizeCountrecord component
-
giveawayMessage
Returns the value of thegiveawayMessagerecord component.- Returns:
- the value of the
giveawayMessagerecord component
-
isStarGiveaway
public boolean isStarGiveaway()Returns the value of theisStarGiveawayrecord component.- Returns:
- the value of the
isStarGiveawayrecord component
-