Record Class QuestClaim
java.lang.Object
java.lang.Record
com.cotani.quest.api.QuestClaim
public record QuestClaim(QuestClaimId claimId, UUID playerId, QuestId questId, com.cotani.reward.api.RewardId rewardId, Instant claimedAt)
extends Record
Immutable successful quest claim that can be handed to the reward service.
-
Constructor Summary
ConstructorsConstructorDescriptionQuestClaim(QuestClaimId claimId, UUID playerId, QuestId questId, com.cotani.reward.api.RewardId rewardId, Instant claimedAt) Creates an instance of aQuestClaimrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theclaimedAtrecord component.claimId()Returns the value of theclaimIdrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.playerId()Returns the value of theplayerIdrecord component.questId()Returns the value of thequestIdrecord component.com.cotani.reward.api.RewardClaimIdReuses the quest idempotency key for the corresponding reward claim.com.cotani.reward.api.RewardIdrewardId()Returns the value of therewardIdrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
QuestClaim
public QuestClaim(QuestClaimId claimId, UUID playerId, QuestId questId, com.cotani.reward.api.RewardId rewardId, Instant claimedAt) Creates an instance of aQuestClaimrecord class.- Parameters:
claimId- the value for theclaimIdrecord componentplayerId- the value for theplayerIdrecord componentquestId- the value for thequestIdrecord componentrewardId- the value for therewardIdrecord componentclaimedAt- the value for theclaimedAtrecord component
-
-
Method Details
-
rewardClaimId
public com.cotani.reward.api.RewardClaimId rewardClaimId()Reuses the quest idempotency key for the corresponding reward claim. -
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). -
claimId
Returns the value of theclaimIdrecord component.- Returns:
- the value of the
claimIdrecord component
-
playerId
Returns the value of theplayerIdrecord component.- Returns:
- the value of the
playerIdrecord component
-
questId
Returns the value of thequestIdrecord component.- Returns:
- the value of the
questIdrecord component
-
rewardId
public com.cotani.reward.api.RewardId rewardId()Returns the value of therewardIdrecord component.- Returns:
- the value of the
rewardIdrecord component
-
claimedAt
Returns the value of theclaimedAtrecord component.- Returns:
- the value of the
claimedAtrecord component
-