Class WrappedGroupProvider

java.lang.Object
io.deephaven.enterprise.dnd.authentication.WrappedGroupProvider
All Implemented Interfaces:
GroupProvider

public class WrappedGroupProvider extends Object implements GroupProvider
A Simple GroupProvider that wraps the Enterprise implementation IrisGroupProvider
  • Constructor Summary

    Constructors
    Constructor
    Description
    WrappedGroupProvider(@NotNull io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.permissions.IrisGroupProvider delegate)
    Create a new provider delegating to the underlying Enterprise provider.
  • Method Summary

    Modifier and Type
    Method
    Description
    getGroupsForUser(@NotNull io.deephaven.enterprise.auth.UserContext userContext)
    Get the groups to which the specified user belongs.
    boolean
    isMember(@NotNull io.deephaven.enterprise.auth.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 io.deephaven.enterprise.auth.UserContext userContext)
    Check if the specified user is a superuser.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • WrappedGroupProvider

      public WrappedGroupProvider(@NotNull @NotNull io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.permissions.IrisGroupProvider delegate)
      Create a new provider delegating to the underlying Enterprise provider.
      Parameters:
      delegate - the Enterprise delegate.
  • Method Details

    • getGroupsForUser

      public String[] getGroupsForUser(@NotNull @NotNull io.deephaven.enterprise.auth.UserContext userContext)
      Description copied from interface: GroupProvider
      Get the groups to which the specified user belongs.
      Specified by:
      getGroupsForUser in interface GroupProvider
      Parameters:
      userContext - the user
      Returns:
      an array of groups the user belongs to.
    • isSuperUser

      public boolean isSuperUser(@NotNull @NotNull io.deephaven.enterprise.auth.UserContext userContext)
      Description copied from interface: GroupProvider
      Check if the specified user is a superuser.
      Specified by:
      isSuperUser in interface GroupProvider
      Parameters:
      userContext - the user
      Returns:
      true if the user was a superuser
    • isMember

      public boolean isMember(@NotNull @NotNull io.deephaven.enterprise.auth.UserContext userContext, @NotNull @NotNull String owner, @NotNull @NotNull String... groups)
      Description copied from interface: GroupProvider
      Check if the specified user is a member or supervisor of any of the specified groups.
      Specified by:
      isMember in interface GroupProvider
      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