Class MappedRoleMapper

  • All Implemented Interfaces:

    public class MappedRoleMapper
    extends Object
    implements RoleMapper
    A simple mapping role mapper. Maps each role to a set of new roles using a String to Set map.
    Martin Mazanek
    • Field Detail

      • initialized

        private volatile boolean initialized
    • Method Detail

      • initialize

        public void initialize​(Map<String,​String> configuration)
        Custom component method. Called from WildFly core. Used to include mapped role mapping functionality in older WildFly versions.
        configuration - map of mapping rules where key is delegate role and value is whitespace separated list of new roles
        IllegalStateException - when called mapper is already initialized
      • mapRoles

        public Roles mapRoles​(Roles rolesToMap)
        Description copied from interface: RoleMapper
        Returns a set of strings representing the roles mapped from the given roles in their raw form.
        Specified by:
        mapRoles in interface RoleMapper
        rolesToMap - the roles in their raw form to apply mapping
        the mapped role set