Interface GroupProvider

All Known Implementing Classes:
WrappedGroupProvider

public interface GroupProvider
A provider for group membership information for users of the system.
  • Method Summary

    Modifier and Type
    Method
    Description
    getGroupsForUser(@NotNull UserContext userContext)
    Get the groups to which the specified user belongs.
    boolean
    isAclEditor(@NotNull UserContext userContext)
    Check if the specified user is an ACL editor.
    boolean
    isMember(@NotNull UserContext userContext, @NotNull String owner, @NotNull String... groups)
    Check if the specified user is a member or supervisor of any of the specified groups.
    boolean
    isSuperUser(@NotNull UserContext userContext)
    Check if the specified user is a superuser.
  • Method Details

    • getGroupsForUser

      String[] getGroupsForUser(@NotNull @NotNull UserContext userContext)
      Get the groups to which the specified user belongs.
      Parameters:
      userContext - the user
      Returns:
      an array of groups the user belongs to.
    • isSuperUser

      boolean isSuperUser(@NotNull @NotNull UserContext userContext)
      Check if the specified user is a superuser.
      Parameters:
      userContext - the user
      Returns:
      true if the user was a superuser
    • isMember

      boolean isMember(@NotNull @NotNull UserContext userContext, @NotNull @NotNull String owner, @NotNull @NotNull String... groups)
      Check if the specified user is a member or supervisor of any of the specified groups.
      Parameters:
      userContext - the user
      owner - the owner of the object
      groups - the groups to check membership of
      Returns:
      true if the user is a member, or supervisor of the specified groups
    • isAclEditor

      boolean isAclEditor(@NotNull @NotNull UserContext userContext)
      Check if the specified user is an ACL editor.
      Parameters:
      userContext - the user
      Returns:
      true if the user is an ACL editor, and false otherwise