Package dev.kitteh.factions.command
Record Class Sender.Player.Impl
java.lang.Object
java.lang.Record
dev.kitteh.factions.command.Sender.Player.Impl
- All Implemented Interfaces:
Sender,Sender.Player
- Enclosing interface:
Sender.Player
public static record Sender.Player.Impl(org.bukkit.command.CommandSender sender, org.bukkit.entity.Player player, FPlayer fPlayer, Faction faction)
extends Record
implements Sender.Player
-
Nested Class Summary
Nested classes/interfaces inherited from interface dev.kitteh.factions.command.Sender
Sender.Console, Sender.PlayerNested classes/interfaces inherited from interface dev.kitteh.factions.command.Sender.Player
Sender.Player.Impl -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.faction()Returns the value of thefactionrecord component.fPlayer()Returns the value of thefPlayerrecord component.final inthashCode()Returns a hash code value for this object.org.bukkit.entity.Playerplayer()Returns the value of theplayerrecord component.org.bukkit.command.CommandSendersender()Returns the value of thesenderrecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface dev.kitteh.factions.command.Sender
canAffordCommand, fPlayerOrNull, hasFaction, hasPermission, isAtLeastRole, isBypass, isPlayer, msg, msgLegacy, payForCommand, sendMessage, sendRichMessage
-
Constructor Details
-
Impl
public Impl(org.bukkit.command.CommandSender sender, org.bukkit.entity.Player player, FPlayer fPlayer, Faction faction) Creates an instance of aImplrecord class.- Parameters:
sender- the value for thesenderrecord componentplayer- the value for theplayerrecord componentfPlayer- the value for thefPlayerrecord componentfaction- the value for thefactionrecord 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. All components in this record class are compared withObjects::equals(Object,Object). -
sender
public org.bukkit.command.CommandSender sender()Returns the value of thesenderrecord component. -
player
public org.bukkit.entity.Player player()Returns the value of theplayerrecord component.- Specified by:
playerin interfaceSender.Player- Returns:
- the value of the
playerrecord component
-
fPlayer
Returns the value of thefPlayerrecord component.- Specified by:
fPlayerin interfaceSender.Player- Returns:
- the value of the
fPlayerrecord component
-
faction
Returns the value of thefactionrecord component.- Specified by:
factionin interfaceSender.Player- Returns:
- the value of the
factionrecord component
-