Class PrimaryGroupHolder.Stored

java.lang.Object
me.lucko.luckperms.common.model.PrimaryGroupHolder.Stored
All Implemented Interfaces:
PrimaryGroupHolder
Direct Known Subclasses:
PrimaryGroupHolder.AllParentsByWeight, PrimaryGroupHolder.ParentsByWeight
Enclosing interface:
PrimaryGroupHolder

public static class PrimaryGroupHolder.Stored extends Object implements PrimaryGroupHolder
Simple implementation which just holds a stored value.
  • Field Details

    • user

      protected final User user
  • Constructor Details

    • Stored

      public Stored(User user)
  • Method Details

    • calculateValue

      public String calculateValue(net.luckperms.api.query.QueryOptions queryOptions)
      Description copied from interface: PrimaryGroupHolder
      Gets the name of the primary group, or null.
      Specified by:
      calculateValue in interface PrimaryGroupHolder
      Parameters:
      queryOptions - the query options to lookup with
      Returns:
      the name of the primary group, or null.
    • getStoredValue

      public Optional<String> getStoredValue()
      Description copied from interface: PrimaryGroupHolder
      Gets the primary group which is stored against the user's data.
      Specified by:
      getStoredValue in interface PrimaryGroupHolder
      Returns:
      the stored value
    • setStoredValue

      public void setStoredValue(String value)
      Description copied from interface: PrimaryGroupHolder
      Sets the primary group which is stored against the user's data.
      Specified by:
      setStoredValue in interface PrimaryGroupHolder
      Parameters:
      value - the new stored value