@DefaultImplementation(value=DefaultRolesFinder.class) public interface RolesFinder
Modifier and Type | Method and Description |
---|---|
default java.util.List<java.lang.String> |
findInClaims(Claims claims)
Deprecated.
use
resolveRoles(Map) instead. |
default boolean |
hasAnyRequiredRoles(java.util.List<java.lang.String> requiredRoles,
Authentication authentication)
Deprecated.
Use
hasAnyRequiredRoles(List, Map) instead. |
default boolean |
hasAnyRequiredRoles(java.util.List<java.lang.String> requiredRoles,
Claims claims)
Deprecated.
Use
hasAnyRequiredRoles(List, Map) instead. |
default boolean |
hasAnyRequiredRoles(java.util.List<java.lang.String> requiredRoles,
java.util.Collection<java.lang.String> grantedRoles) |
default boolean |
hasAnyRequiredRoles(java.util.List<java.lang.String> requiredRoles,
java.util.Map<java.lang.String,java.lang.Object> attributes) |
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.
|
@Deprecated @NonNull default java.util.List<java.lang.String> findInClaims(@NonNull Claims claims)
resolveRoles(Map)
instead.claims
- The claims of the token.@Deprecated default boolean hasAnyRequiredRoles(@NonNull java.util.List<java.lang.String> requiredRoles, @NonNull Authentication authentication)
hasAnyRequiredRoles(List, Map)
instead.requiredRoles
- The list of roles required to be authorizedauthentication
- The authentication@Deprecated default boolean hasAnyRequiredRoles(@NonNull java.util.List<java.lang.String> requiredRoles, @NonNull Claims claims)
hasAnyRequiredRoles(List, Map)
instead.requiredRoles
- The list of roles required to be authorizedclaims
- The claims of the token.default boolean hasAnyRequiredRoles(@NonNull java.util.List<java.lang.String> requiredRoles, @Nullable java.util.Map<java.lang.String,java.lang.Object> attributes)
requiredRoles
- The list of roles required to be authorizedattributes
- User's attributesdefault boolean hasAnyRequiredRoles(@NonNull java.util.List<java.lang.String> requiredRoles, @NonNull java.util.Collection<java.lang.String> grantedRoles)
requiredRoles
- The list of roles required to be authorizedgrantedRoles
- The list of roles granted to the user@NonNull java.util.List<java.lang.String> resolveRoles(@Nullable java.util.Map<java.lang.String,java.lang.Object> attributes)
attributes
- User's attributes