Record Class FPlayer.FPlayerImpl

java.lang.Object
java.lang.Record
net.flectone.pulse.model.entity.FPlayer.FPlayerImpl
All Implemented Interfaces:
FEntity, FPlayer
Enclosing interface:
FPlayer

public static record FPlayer.FPlayerImpl(String name, UUID uuid, String type, Integer id, boolean online, @Nullable String ip, List<net.kyori.adventure.text.Component> constants, @Nullable net.kyori.adventure.text.Component showEntityName) extends Record implements FPlayer
  • Constructor Details

    • FPlayerImpl

      public FPlayerImpl(String name, UUID uuid, String type, Integer id, boolean online, @Nullable String ip, List<net.kyori.adventure.text.Component> constants, @Nullable net.kyori.adventure.text.Component showEntityName)
      Creates an instance of a FPlayerImpl record class.
      Parameters:
      name - the value for the name record component
      uuid - the value for the uuid record component
      type - the value for the type record component
      id - the value for the id record component
      online - the value for the online record component
      ip - the value for the ip record component
      constants - the value for the constants record component
      showEntityName - the value for the showEntityName record component
  • Method Details

    • isConsole

      public boolean isConsole()
      Specified by:
      isConsole in interface FPlayer
    • isIntegration

      public boolean isIntegration()
      Specified by:
      isIntegration in interface FPlayer
    • isOnline

      public boolean isOnline()
      Specified by:
      isOnline in interface FPlayer
    • equals

      public boolean equals(Object object)
      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 with Objects::equals(Object,Object); primitive components are compared with the compare method from their corresponding wrapper classes.
      Specified by:
      equals in class Record
      Parameters:
      object - the object with which to compare
      Returns:
      true if this object is the same as the object argument; false otherwise.
    • hashCode

      public int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • withConstants

      public FPlayer withConstants(@Nullable List<net.kyori.adventure.text.Component> constants)
      Specified by:
      withConstants in interface FPlayer
    • builder

      public static FPlayer.FPlayerImpl.FPlayerImplBuilder builder()
    • toBuilder

      Specified by:
      toBuilder in interface FPlayer
    • withName

      public FPlayer.FPlayerImpl withName(String name)
      Specified by:
      withName in interface FPlayer
      Returns:
      a clone of this object, except with this updated property (returns this if an identical value is passed).
    • withUuid

      public FPlayer.FPlayerImpl withUuid(UUID uuid)
      Specified by:
      withUuid in interface FPlayer
      Returns:
      a clone of this object, except with this updated property (returns this if an identical value is passed).
    • withType

      public FPlayer.FPlayerImpl withType(String type)
      Returns:
      a clone of this object, except with this updated property (returns this if an identical value is passed).
    • withId

      public FPlayer.FPlayerImpl withId(Integer id)
      Specified by:
      withId in interface FPlayer
      Returns:
      a clone of this object, except with this updated property (returns this if an identical value is passed).
    • withOnline

      public FPlayer.FPlayerImpl withOnline(boolean online)
      Specified by:
      withOnline in interface FPlayer
      Returns:
      a clone of this object, except with this updated property (returns this if an identical value is passed).
    • withIp

      public FPlayer.FPlayerImpl withIp(@Nullable String ip)
      Specified by:
      withIp in interface FPlayer
      Returns:
      a clone of this object, except with this updated property (returns this if an identical value is passed).
    • withShowEntityName

      public FPlayer.FPlayerImpl withShowEntityName(@Nullable net.kyori.adventure.text.Component showEntityName)
      Returns:
      a clone of this object, except with this updated property (returns this if an identical value is passed).
    • toString

      public final String 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.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • name

      public String name()
      Returns the value of the name record component.
      Specified by:
      name in interface FEntity
      Returns:
      the value of the name record component
    • uuid

      public UUID uuid()
      Returns the value of the uuid record component.
      Specified by:
      uuid in interface FEntity
      Returns:
      the value of the uuid record component
    • type

      public String type()
      Returns the value of the type record component.
      Specified by:
      type in interface FEntity
      Returns:
      the value of the type record component
    • id

      public Integer id()
      Returns the value of the id record component.
      Specified by:
      id in interface FPlayer
      Returns:
      the value of the id record component
    • online

      public boolean online()
      Returns the value of the online record component.
      Returns:
      the value of the online record component
    • ip

      public @Nullable String ip()
      Returns the value of the ip record component.
      Specified by:
      ip in interface FPlayer
      Returns:
      the value of the ip record component
    • constants

      public List<net.kyori.adventure.text.Component> constants()
      Returns the value of the constants record component.
      Specified by:
      constants in interface FPlayer
      Returns:
      the value of the constants record component
    • showEntityName

      public @Nullable net.kyori.adventure.text.Component showEntityName()
      Returns the value of the showEntityName record component.
      Specified by:
      showEntityName in interface FEntity
      Returns:
      the value of the showEntityName record component