org.wildfly.swarm.config.elytron

## Class MappedRegexRealmMapper<T extends MappedRegexRealmMapper<T>>

- java.lang.Object
- - org.wildfly.swarm.config.elytron.MappedRegexRealmMapper<T>

-     public class MappedRegexRealmMapper<T extends MappedRegexRealmMapper<T>>
      extends Object

  Definition of a RealmMapper implementation that first uses a regular expression to extract the realm name, this is then converted using the configured mapping of realm names.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `MappedRegexRealmMapper(String key)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `addPropertyChangeListener(PropertyChangeListener listener)` Adds a property change listener
    `String` | `delegateRealmMapper()` The RealmMapper to delegate to if the pattern does not match.
    `T` | `delegateRealmMapper(String value)` The RealmMapper to delegate to if the pattern does not match.
    `String` | `getKey()`
    `String` | `pattern()` The regular expression which must contain at least one capture group to extract the realm from the name.
    `T` | `pattern(String value)` The regular expression which must contain at least one capture group to extract the realm from the name.
    `Map` | `realmMap()` Mapping of realm name extracted using the regular expression to a defined realm name.
    `T` | `realmMap(Map value)` Mapping of realm name extracted using the regular expression to a defined realm name.
    `T` | `realmMap(String key, Object value)` Mapping of realm name extracted using the regular expression to a defined realm name.
    `void` | `removePropertyChangeListener(PropertyChangeListener listener)` Removes a property change listener

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### MappedRegexRealmMapper

          public MappedRegexRealmMapper(String key)

  - ### Method Detail

    - #### getKey

          public String getKey()

    - #### addPropertyChangeListener

          public void addPropertyChangeListener(PropertyChangeListener listener)

      Adds a property change listener

    - #### removePropertyChangeListener

          public void removePropertyChangeListener(PropertyChangeListener listener)

      Removes a property change listener

    - #### delegateRealmMapper

          public String delegateRealmMapper()

      The RealmMapper to delegate to if the pattern does not match. If no delegate is specified then the default realm on the domain will be used instead. If the username does not match the pattern and a delegate realm-mapper is present, the result of delegate-realm-mapper is mapped via the realm-map.

    - #### delegateRealmMapper

          public T delegateRealmMapper(String value)

      The RealmMapper to delegate to if the pattern does not match. If no delegate is specified then the default realm on the domain will be used instead. If the username does not match the pattern and a delegate realm-mapper is present, the result of delegate-realm-mapper is mapped via the realm-map.

    - #### pattern

          public String pattern()

      The regular expression which must contain at least one capture group to extract the realm from the name. If the regular expression matches more than one capture group, the first capture group is used.

    - #### pattern

          public T pattern(String value)

      The regular expression which must contain at least one capture group to extract the realm from the name. If the regular expression matches more than one capture group, the first capture group is used.

    - #### realmMap

          public Map realmMap()

      Mapping of realm name extracted using the regular expression to a defined realm name. If the value for the mapping is not in the map or the realm whose name is the result of the mapping does not exist in the given security domain, the default realm is used.

    - #### realmMap

          public T realmMap(Map value)

      Mapping of realm name extracted using the regular expression to a defined realm name. If the value for the mapping is not in the map or the realm whose name is the result of the mapping does not exist in the given security domain, the default realm is used.

    - #### realmMap

          public T realmMap(String key,
                            Object value)

      Mapping of realm name extracted using the regular expression to a defined realm name. If the value for the mapping is not in the map or the realm whose name is the result of the mapping does not exist in the given security domain, the default realm is used.

Copyright © 2018 JBoss by Red Hat. All rights reserved.