Package org.h2.api

Interface UserToRolesMapper

  • All Superinterfaces:
    Configurable
    All Known Implementing Classes:
    AssignRealmNameRole, StaticRolesMapper

    public interface UserToRolesMapper
    extends Configurable
    A class that implement this interface can be used during authentication to map external users to database roles.

    This feature is experimental and subject to change

    • Method Detail

      • mapUserToRoles

        java.util.Collection<java.lang.String> mapUserToRoles​(AuthenticationInfo authenticationInfo)
                                                       throws AuthenticationException
        Map user identified by authentication info to a set of granted roles.
        Parameters:
        authenticationInfo - authentication information
        Returns:
        list of roles to be assigned to the user temporary
        Throws:
        AuthenticationException - on authentication exception