org.jboss.jca.core.security
Class DefaultCallback

java.lang.Object
  extended by org.jboss.jca.core.security.DefaultCallback
All Implemented Interfaces:
Serializable, org.jboss.jca.core.spi.security.Callback

public class DefaultCallback
extends Object
implements org.jboss.jca.core.spi.security.Callback

A default implementation of the callback security SPI.

Author:
Jesper Pedersen
See Also:
Serialized Form

Constructor Summary
DefaultCallback()
          Constructor
DefaultCallback(String file)
          Constructor
 
Method Summary
 void addGroupMapping(String from, String to)
          Add a group mapping
 void addPrincipalMapping(String from, String to)
          Add a principal mapping
 String[] getDefaultGroups()
          
 Principal getDefaultPrincipal()
          
 String getDomain()
          
 boolean isMappingRequired()
          
 String mapGroup(String name)
          
 Principal mapPrincipal(String name)
          
 void setDefaultGroups(String[] value)
          Set the default groups
 void setDefaultPrincipal(Principal value)
          Set the default principal
 void setDomain(String v)
          Set the domain
 void setFile(String value)
          Set the file name
 void setMappingRequired(boolean value)
          Set the user mapping required
 void start()
          
 void stop()
          
 String toString()
          
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DefaultCallback

public DefaultCallback()
Constructor


DefaultCallback

public DefaultCallback(String file)
Constructor

Parameters:
file - The file
Method Detail

getDomain

public String getDomain()

Specified by:
getDomain in interface org.jboss.jca.core.spi.security.Callback

setDomain

public void setDomain(String v)
Set the domain

Parameters:
v - The value

isMappingRequired

public boolean isMappingRequired()

Specified by:
isMappingRequired in interface org.jboss.jca.core.spi.security.Callback

setMappingRequired

public void setMappingRequired(boolean value)
Set the user mapping required

Parameters:
value - The value

getDefaultPrincipal

public Principal getDefaultPrincipal()

Specified by:
getDefaultPrincipal in interface org.jboss.jca.core.spi.security.Callback

setDefaultPrincipal

public void setDefaultPrincipal(Principal value)
Set the default principal

Parameters:
value - The value

getDefaultGroups

public String[] getDefaultGroups()

Specified by:
getDefaultGroups in interface org.jboss.jca.core.spi.security.Callback

setDefaultGroups

public void setDefaultGroups(String[] value)
Set the default groups

Parameters:
value - The value

mapPrincipal

public Principal mapPrincipal(String name)

Specified by:
mapPrincipal in interface org.jboss.jca.core.spi.security.Callback

addPrincipalMapping

public void addPrincipalMapping(String from,
                                String to)
Add a principal mapping

Parameters:
from - The from name
to - The to name

mapGroup

public String mapGroup(String name)

Specified by:
mapGroup in interface org.jboss.jca.core.spi.security.Callback

addGroupMapping

public void addGroupMapping(String from,
                            String to)
Add a group mapping

Parameters:
from - The from name
to - The to name

setFile

public void setFile(String value)
Set the file name

Parameters:
value - The value

start

public void start()
           throws Throwable

Specified by:
start in interface org.jboss.jca.core.spi.security.Callback
Throws:
Throwable

stop

public void stop()
          throws Throwable

Specified by:
stop in interface org.jboss.jca.core.spi.security.Callback
Throws:
Throwable

toString

public String toString()

Overrides:
toString in class Object


Copyright © 2012 JBoss, by Red Hat (http://www.jboss.org/ironjacamar)