Package io.micronaut.security.token
Class DefaultRolesFinder
- java.lang.Object
-
- io.micronaut.security.token.DefaultRolesFinder
-
- All Implemented Interfaces:
RolesFinder
@Singleton public class DefaultRolesFinder extends java.lang.Object implements RolesFinder
Default implementation ofRolesFinder.- Since:
- 1.1.0
-
-
Constructor Summary
Constructors Constructor Description DefaultRolesFinder(TokenConfiguration tokenConfiguration)Constructs a Roles Parser.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<java.lang.String>resolveRoles(java.util.Map<java.lang.String,java.lang.Object> attributes)Retrieves the list of roles from the User Attributes.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.micronaut.security.token.RolesFinder
findInClaims, hasAnyRequiredRoles, hasAnyRequiredRoles, hasAnyRequiredRoles, hasAnyRequiredRoles
-
-
-
-
Constructor Detail
-
DefaultRolesFinder
public DefaultRolesFinder(TokenConfiguration tokenConfiguration)
Constructs a Roles Parser.- Parameters:
tokenConfiguration- General Token Configuration
-
-
Method Detail
-
resolveRoles
@NonNull public java.util.List<java.lang.String> resolveRoles(@Nullable java.util.Map<java.lang.String,java.lang.Object> attributes)Description copied from interface:RolesFinderRetrieves the list of roles from the User Attributes.- Specified by:
resolveRolesin interfaceRolesFinder- Parameters:
attributes- User's attributes- Returns:
- The granted roles.
-
-