Record Class EliminationSnapshot
java.lang.Object
java.lang.Record
dev.itsharshxd.zentrix.api.revival.EliminationSnapshot
public record EliminationSnapshot(@NotNull UUID playerId, @NotNull String teamId, @Nullable org.bukkit.inventory.ItemStack[] lostLoot)
extends Record
Immutable view of one player elimination retained for teammate revival.
-
Constructor Summary
ConstructorsConstructorDescriptionEliminationSnapshot(@NotNull UUID playerId, @NotNull String teamId, @Nullable org.bukkit.inventory.ItemStack[] lostLoot) Creates an instance of aEliminationSnapshotrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.org.bukkit.inventory.ItemStack[]lostLoot()Returns the value of thelostLootrecord component.@NotNull UUIDplayerId()Returns the value of theplayerIdrecord component.@NotNull StringteamId()Returns the value of theteamIdrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
EliminationSnapshot
public EliminationSnapshot(@NotNull @NotNull UUID playerId, @NotNull @NotNull String teamId, @Nullable @Nullable org.bukkit.inventory.ItemStack[] lostLoot) Creates an instance of aEliminationSnapshotrecord class.- Parameters:
playerId- the value for theplayerIdrecord componentteamId- the value for theteamIdrecord componentlostLoot- the value for thelostLootrecord component
-
-
Method Details
-
lostLoot
public org.bukkit.inventory.ItemStack[] lostLoot()Returns the value of thelostLootrecord component.- Returns:
- the value of the
lostLootrecord component
-
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). -
playerId
Returns the value of theplayerIdrecord component.- Returns:
- the value of the
playerIdrecord component
-
teamId
Returns the value of theteamIdrecord component.- Returns:
- the value of the
teamIdrecord component
-