Class WarlockGrantServiceDummy

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      void grantRole(long roleId, @NotNull() GrantType type, @NotNull() Collection<Long> grant) Grant role/perm to role to give the `grant` privilege.
      void purgeRole(long roleId, @NotNull() GrantType type, @NotNull() Collection<Long> grant) Revoke role/perm to role to remove the `grant` privilege.
      void grantUser(long userId, @NotNull() GrantType type, @NotNull() Collection<Long> grant) Grant role/perm to user to give the `grant` privilege.
      void purgeUser(long userId, @NotNull() GrantType type, @NotNull() Collection<Long> grant) Revoke role/perm to user to remove the `grant` privilege.
      Map<Long, Set<Long>> entryUser(@NotNull() GrantType type, @NotNull() Collection<Long> userId) Get user granted privileges.
      Map<Long, Set<Long>> entryRole(@NotNull() GrantType type, @NotNull() Collection<Long> roleId) Get role granted privileges.
      • Methods inherited from class pro.fessional.wings.warlock.service.grant.WarlockGrantService

        entryRole, entryUser, grantRole, grantUser, purgeRole, purgeUser
      • Methods inherited from class java.lang.Object

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

      • WarlockGrantServiceDummy

        WarlockGrantServiceDummy()
    • Method Detail

      • grantRole

         void grantRole(long roleId, @NotNull() GrantType type, @NotNull() Collection<Long> grant)

        Grant role/perm to role to give the `grant` privilege.

        Parameters:
        roleId - roleId
        type - grant type
        grant - RoleId or PermId
      • purgeRole

         void purgeRole(long roleId, @NotNull() GrantType type, @NotNull() Collection<Long> grant)

        Revoke role/perm to role to remove the `grant` privilege.

        Parameters:
        roleId - roleId
        type - grant type
        grant - RoleId or PermId
      • grantUser

         void grantUser(long userId, @NotNull() GrantType type, @NotNull() Collection<Long> grant)

        Grant role/perm to user to give the `grant` privilege.

        Parameters:
        userId - userId
        type - grant type
        grant - RoleId or PermId
      • purgeUser

         void purgeUser(long userId, @NotNull() GrantType type, @NotNull() Collection<Long> grant)

        Revoke role/perm to user to remove the `grant` privilege.

        Parameters:
        userId - userId
        type - grant type
        grant - RoleId or PermId
      • entryUser

         Map<Long, Set<Long>> entryUser(@NotNull() GrantType type, @NotNull() Collection<Long> userId)

        Get user granted privileges. return the map of RoleId/PermId to UserId

        Parameters:
        type - grant type
        userId - userId
        Returns:

        RoleId/PermId - UserId

      • entryRole

         Map<Long, Set<Long>> entryRole(@NotNull() GrantType type, @NotNull() Collection<Long> roleId)

        Get role granted privileges. return the map of RoleId/PermId to UserId

        Parameters:
        type - grant type
        roleId - roleId
        Returns:

        RoleId/PermId - roleId