org.jboss.jca.core.security

## Class CallbackImpl

- java.lang.Object
- - org.jboss.jca.core.security.AbstractCallback
  - - org.jboss.jca.core.security.CallbackImpl

- All Implemented Interfaces:
    java.io.Serializable, org.jboss.jca.core.spi.security.Callback

      public class CallbackImpl
      extends AbstractCallback
      implements org.jboss.jca.core.spi.security.Callback

  An implementation of the callback SPI for explicit security settings
  Author:
    Jesper Pedersen
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `CallbackImpl(boolean mappingRequired, java.lang.String domain, java.lang.String defaultPrincipal, java.lang.String[] defaultGroups, java.util.Map<java.lang.String,java.lang.String> principals, java.util.Map<java.lang.String,java.lang.String> groups)` Constructor

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.lang.String[]` | `getDefaultGroups()` Get the default groups
    `java.security.Principal` | `getDefaultPrincipal()` Get the default principal
    `java.lang.String` | `getDomain()` Get the domain
    `boolean` | `isMappingRequired()` Is an user mapping required
    `java.lang.String` | `mapGroup(java.lang.String name)` Map a group
    `java.security.Principal` | `mapPrincipal(java.lang.String name)` Map a principal
    `void` | `start()` Start
    `void` | `stop()` Stop
    `java.lang.String` | `toString()`

    - ### Methods inherited from class org.jboss.jca.core.security.AbstractCallback

      `mapCallbacks`

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

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface org.jboss.jca.core.spi.security.Callback

      `mapCallbacks`

- - ### Constructor Detail

    - #### CallbackImpl

          public CallbackImpl(boolean mappingRequired,
                              java.lang.String domain,
                              java.lang.String defaultPrincipal,
                              java.lang.String[] defaultGroups,
                              java.util.Map<java.lang.String,java.lang.String> principals,
                              java.util.Map<java.lang.String,java.lang.String> groups)

      Constructor
      Parameters:
        `mappingRequired` - Is a mapping required
        `domain` - The domain
        `defaultPrincipal` - The default principal
        `defaultGroups` - The default groups
        `principals` - The principal mappings
        `groups` - The group mappings

  - ### Method Detail

    - #### isMappingRequired

          public boolean isMappingRequired()

      Is an user mapping required
      Specified by:
        `isMappingRequired` in interface `org.jboss.jca.core.spi.security.Callback`
      Returns:
        The value

    - #### getDomain

          public java.lang.String getDomain()

      Get the domain
      Specified by:
        `getDomain` in interface `org.jboss.jca.core.spi.security.Callback`
      Returns:
        The domain

    - #### getDefaultPrincipal

          public java.security.Principal getDefaultPrincipal()

      Get the default principal
      Specified by:
        `getDefaultPrincipal` in interface `org.jboss.jca.core.spi.security.Callback`
      Returns:
        The value; `null` if no default principal

    - #### getDefaultGroups

          public java.lang.String[] getDefaultGroups()

      Get the default groups
      Specified by:
        `getDefaultGroups` in interface `org.jboss.jca.core.spi.security.Callback`
      Returns:
        The value; `null` if no default groups

    - #### mapPrincipal

          public java.security.Principal mapPrincipal(java.lang.String name)

      Map a principal
      Specified by:
        `mapPrincipal` in interface `org.jboss.jca.core.spi.security.Callback`
      Parameters:
        `name` - The principal name
      Returns:
        The value; `null` if no mapping could be found

    - #### mapGroup

          public java.lang.String mapGroup(java.lang.String name)

      Map a group
      Specified by:
        `mapGroup` in interface `org.jboss.jca.core.spi.security.Callback`
      Parameters:
        `name` - The group name
      Returns:
        The value; `null` if no mapping could be found

    - #### start

          public void start()
                     throws java.lang.Throwable

      Start
      Specified by:
        `start` in interface `org.jboss.jca.core.spi.security.Callback`
      Throws:
        `java.lang.Throwable` - Thrown if an error occurs

    - #### stop

          public void stop()
                    throws java.lang.Throwable

      Stop
      Specified by:
        `stop` in interface `org.jboss.jca.core.spi.security.Callback`
      Throws:
        `java.lang.Throwable` - Thrown if an error occurs

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `java.lang.Object`

Copyright © 2014 IronJacamar (http://www.ironjacamar.org)