Class DatabaseRolesMappingProvider
- java.lang.Object
-
- org.jboss.security.mapping.providers.role.AbstractRolesMappingProvider
-
- org.jboss.security.mapping.providers.role.DatabaseRolesMappingProvider
-
- All Implemented Interfaces:
MappingProvider<RoleGroup>
public class DatabaseRolesMappingProvider extends AbstractRolesMappingProvider
AMappingProviderthat reads roles from a database. rolesQuery option should be a prepared statement equivalent to "select RoleName from Roles where User=?"- Author:
- Marcus Moyses
-
-
Field Summary
Fields Modifier and Type Field Description protected StringdsJndiNameprotected StringrolesQueryprotected booleansuspendResumeprotected TransactionManagertmprotected StringTX_MGR_JNDI_NAME-
Fields inherited from class org.jboss.security.mapping.providers.role.AbstractRolesMappingProvider
result
-
-
Constructor Summary
Constructors Constructor Description DatabaseRolesMappingProvider()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected TransactionManagergetTransactionManager()voidinit(Map<String,Object> options)Initialize the provider with the configured module optionsvoidperformMapping(Map<String,Object> contextMap, RoleGroup mappedObject)Map the passed object-
Methods inherited from class org.jboss.security.mapping.providers.role.AbstractRolesMappingProvider
getCallerPrincipal, setMappingResult, supports
-
-
-
-
Field Detail
-
dsJndiName
protected String dsJndiName
-
rolesQuery
protected String rolesQuery
-
suspendResume
protected boolean suspendResume
-
TX_MGR_JNDI_NAME
protected String TX_MGR_JNDI_NAME
-
tm
protected TransactionManager tm
-
-
Method Detail
-
init
public void init(Map<String,Object> options)
Description copied from interface:MappingProviderInitialize the provider with the configured module options
-
performMapping
public void performMapping(Map<String,Object> contextMap, RoleGroup mappedObject)
Description copied from interface:MappingProviderMap the passed object- Parameters:
contextMap- A read-only contextual map that can provide information to the providermappedObject- an Object on which the mapping will be applied
-
getTransactionManager
protected TransactionManager getTransactionManager() throws NamingException
- Throws:
NamingException
-
-