All Known Subinterfaces:
GroupRoot

public interface Group
Interface representing a group used in the permission service.
Since:
3.1.170
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    Creates a new group with the given name as child of this group and appends it to the list of children.
    Creates a new group with the given name and id as child of this group and appends it to the list of children.
    void
    Removes all children of this group.
    @NotNull List<Group>
    Returns a list of all (recursive) group children of this group.
    Deprecated.
    since 4.2.200 - use getAllChildren() instead
    Returns a list of all parents existing on the parent path of this group.
    Collection<? extends Group>
    Returns a collection of all direct sub group children.
    Returns the id of this group.
    int
    Returns the depth level of this group.
    Returns the name of this group or null if not set
    @Nullable Group
    Returns the parent group of this group or nullif this group is the root group
    boolean
    Indicates whether this group has an id or not.
    boolean
    Indicates whether this group is selectable in the permission editor component or not.
    void
    Removes the given group from the list
    void
    Removes the id of this group.
    void
    Sets the id of this group.
    void
    Sets the name for this group.
    void
    setSelectable(boolean selectable)
    Make this group selectable in the permission editor component ( true) or not false.
  • Method Details

    • getChildren

      Collection<? extends Group> getChildren()
      Returns a collection of all direct sub group children.
      Returns:
      a collection of direct sub groups.
      Since:
      4.2.200
    • getParent

      @Nullable @Nullable Group getParent()
      Returns the parent group of this group or nullif this group is the root group
      Returns:
      the parent of this group or null in case of the group root
      Since:
      3.1.170
    • getLevel

      int getLevel()
      Returns the depth level of this group. In case of root group the level is 0
      Returns:
      the level of this group.
      Since:
      3.1.324
    • getId

      String getId()
      Returns the id of this group.
      Returns:
      the id of this group.
      Since:
      3.1.170
      See Also:
    • setId

      void setId(String id)
      Sets the id of this group.
      Parameters:
      id - the new id
      Since:
      3.1.170
      See Also:
    • removeId

      void removeId()
      Removes the id of this group.
      Since:
      3.1.170
    • hasId

      boolean hasId()
      Indicates whether this group has an id or not.
      Returns:
      true if this group has an id, false otherwise
      Since:
      3.1.170
    • getName

      String getName()
      Returns the name of this group or null if not set
      Returns:
      the name of this group or null
      Since:
      3.1.170
      See Also:
    • setName

      void setName(String name)
      Sets the name for this group.
      Parameters:
      name - the name to be used for this group.
      Since:
      3.1.170
      See Also:
    • removeChild

      void removeChild(Group group)
      Removes the given group from the list
      Parameters:
      group - the group to remove
      Since:
      3.1.170
    • clearChildren

      void clearChildren()
      Removes all children of this group.
      Since:
      4.2.200
    • getAllChilds

      @Deprecated List<Group> getAllChilds()
      Deprecated.
      since 4.2.200 - use getAllChildren() instead
      Since:
      3.1.170
    • getAllChildren

      @NotNull @NotNull List<Group> getAllChildren()
      Returns a list of all (recursive) group children of this group.
      Returns:
      a list of all (recursive) group children of this group
      Since:
      4.2.200
      See Also:
    • getAllParents

      List<Group> getAllParents()
      Returns a list of all parents existing on the parent path of this group. The first element of returned list is the direct parent and the lastelement is the root group this group belongs to.
      Returns:
      a list of all parents existing on the parent path.
      Since:
      3.1.324
    • appendChild

      Group appendChild(String name)
      Creates a new group with the given name as child of this group and appends it to the list of children.
      Parameters:
      name - the name for the new group
      Returns:
      the created group
      Since:
      3.1.170
    • appendChild

      Group appendChild(String id, String name)
      Creates a new group with the given name and id as child of this group and appends it to the list of children.
      Parameters:
      name - the name for the new group
      id - the id for the new group
      Returns:
      the created group
      Since:
      3.1.170
    • isSelectable

      boolean isSelectable()
      Indicates whether this group is selectable in the permission editor component or not.
      Returns:
      true if this group is selectable in permission editor, false otherwise
      Since:
      3.1.170
      See Also:
    • setSelectable

      void setSelectable(boolean selectable)
      Make this group selectable in the permission editor component ( true) or not false.
      Parameters:
      selectable - use true to make this group selectable in permission editor, false otherwise
      Since:
      3.1.170
      See Also: