Package org.forgerock.audit.providers
Class DefaultSecureStorageProvider
- java.lang.Object
-
- org.forgerock.audit.providers.DefaultSecureStorageProvider
-
- All Implemented Interfaces:
SecureStorageProvider
public class DefaultSecureStorageProvider extends Object implements SecureStorageProvider
Default implementation ofSecureStorageProvider
.Multiple SecureStorage instances can be provided, identified by a name.
-
-
Constructor Summary
Constructors Constructor Description DefaultSecureStorageProvider()
Creates a initially empty provider.DefaultSecureStorageProvider(Map<String,SecureStorage> storages)
Creates a provider with some storages instances.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SecureStorage
getSecureStorage(String name)
Returns the secure storage corresponding to the given name.void
registerSecureStorage(String name, SecureStorage storage)
Register a storage with the given name.
-
-
-
Constructor Detail
-
DefaultSecureStorageProvider
public DefaultSecureStorageProvider()
Creates a initially empty provider.
-
DefaultSecureStorageProvider
public DefaultSecureStorageProvider(Map<String,SecureStorage> storages)
Creates a provider with some storages instances.- Parameters:
storages
- The storage instances to use in the provider.
-
-
Method Detail
-
registerSecureStorage
public void registerSecureStorage(String name, SecureStorage storage)
Register a storage with the given name.- Parameters:
name
- Name associated to the storage instance.storage
- The storage instance.
-
getSecureStorage
public SecureStorage getSecureStorage(String name)
Description copied from interface:SecureStorageProvider
Returns the secure storage corresponding to the given name.- Specified by:
getSecureStorage
in interfaceSecureStorageProvider
- Parameters:
name
- The name of instance to retrieve- Returns:
- the secure storage
-
-