Interface SessionKey

All Superinterfaces:
Identifiable

public interface SessionKey extends Identifiable
Provides information about a session.

A reference for this object may be kept around for a long time.

  • Field Summary

    Fields inherited from interface com.sk89q.worldedit.util.Identifiable

    CONSOLE, EVERYONE
  • Method Summary

    Modifier and Type
    Method
    Description
    Get the name for this session, if one is available, so that it can be referred to by others.
    boolean
    Return whether the session is still active.
    boolean
    Return whether this session should be persisted.

    Methods inherited from interface com.sk89q.worldedit.util.Identifiable

    getUniqueId
  • Method Details

    • getName

      @Nullable String getName()
      Get the name for this session, if one is available, so that it can be referred to by others.
      Returns:
      a name or null
    • isActive

      boolean isActive()
      Return whether the session is still active. Sessions that are inactive for a prolonged amount of time may be removed. If this method always returns false, the the related session may never be stored.

      This method may be called from any thread, so this call must be thread safe.

      Returns:
      true if active
    • isPersistent

      boolean isPersistent()
      Return whether this session should be persisted.
      Returns:
      true if persistent