Class WrappedRemoteChatSessionData

java.lang.Object
com.comphenix.protocol.wrappers.AbstractWrapper
com.comphenix.protocol.wrappers.WrappedRemoteChatSessionData

public class WrappedRemoteChatSessionData extends AbstractWrapper
A wrapper around the remote chat session.
Since:
1.19.3
  • Constructor Details

    • WrappedRemoteChatSessionData

      public WrappedRemoteChatSessionData(Object handle)
      Constructs a new profile public key wrapper directly from a nms RemoteChatSession.Data/RemoteChatSession.a object.
      Parameters:
      handle - the handle to create the wrapper from.
    • WrappedRemoteChatSessionData

      public WrappedRemoteChatSessionData(UUID sessionId, WrappedProfilePublicKey.WrappedProfileKeyData profilePublicKey)
  • Method Details

    • getSessionID

      public UUID getSessionID()
      Retrieves the id of the current session
      Returns:
      session id
    • setSessionID

      public void setSessionID(UUID sessionId)
      Set the id for this session
      Parameters:
      sessionId - new session id
    • getProfilePublicKey

      public WrappedProfilePublicKey.WrappedProfileKeyData getProfilePublicKey()
      Retrieves the ProfileKeyData
      Returns:
      the public key data for this session
    • setProfilePublicKey

      public void setProfilePublicKey(WrappedProfilePublicKey.WrappedProfileKeyData data)
      Set the profile key data for this session
      Parameters:
      data - ProfileKeyData
    • setHandle

      protected void setHandle(Object handle)
      Description copied from class: AbstractWrapper
      Set the underlying NMS object.
      Overrides:
      setHandle in class AbstractWrapper
      Parameters:
      handle - - the NMS object.
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class AbstractWrapper
    • toString

      public String toString()
      Overrides:
      toString in class AbstractWrapper
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class AbstractWrapper
    • fromPlayer

      @Nullable public static WrappedRemoteChatSessionData fromPlayer(org.bukkit.entity.Player player)
      Retrieves the current session data of the player
      Returns:
      Wrapper for session data or null if not present
      Since:
      1.19.4