org.apache.jackrabbit.core.security.principal
Interface PrincipalProviderRegistry

All Known Implementing Classes:
ProviderRegistryImpl

public interface PrincipalProviderRegistry

Registry used to store and retrieve PrincipalProviders.

See Also:
PrincipalProvider

Method Summary
 PrincipalProvider getDefault()
           
 PrincipalProvider getProvider(String className)
           
 PrincipalProvider[] getProviders()
          Returns all registered providers.
 PrincipalProvider registerProvider(Properties configuration)
          Registers a new provider by means of a configuration.
 

Method Detail

registerProvider

PrincipalProvider registerProvider(Properties configuration)
                                   throws RepositoryException
Registers a new provider by means of a configuration. The registry expects the properties to contain a LoginModuleConfig.PARAM_PRINCIPAL_PROVIDER_CLASS to be able to create a instance of PrincipalProvider.

The Properties will be passed to the instanciated Provider via PrincipalProvider.init(Properties)

Parameters:
configuration - Properties for the Provider
Returns:
the newly added Provider or null if the configuration was incomplete.
Throws:
RepositoryException - if an error occurs while creating the provider instance.

getDefault

PrincipalProvider getDefault()
Returns:
the default principal provider

getProvider

PrincipalProvider getProvider(String className)
Parameters:
className - Name of the principal provider class.
Returns:
PrincipalProvider or null if no provider with the given class name was registered.

getProviders

PrincipalProvider[] getProviders()
Returns all registered providers.

Returns:
all registered providers.


Copyright © 2004-2010 The Apache Software Foundation. All Rights Reserved.