org.apache.myfaces.extensions.validator.core.storage
Class DefaultStorageManagerFactory
java.lang.Object
org.apache.myfaces.extensions.validator.core.factory.AbstractNameMapperAwareFactory<Class>
org.apache.myfaces.extensions.validator.core.storage.DefaultStorageManagerFactory
- All Implemented Interfaces:
- ClassMappingFactory<Class,StorageManager>, NameMapperAwareFactory<NameMapper<Class>>, StorageManagerHolder
public class DefaultStorageManagerFactory
- extends AbstractNameMapperAwareFactory<Class>
- implements ClassMappingFactory<Class,StorageManager>, StorageManagerHolder
default implementation for storage-manager creation and caching
- Since:
- x.x.3
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
logger
protected final Logger logger
DefaultStorageManagerFactory
public DefaultStorageManagerFactory()
create
public StorageManager create(Class storageType)
- Description copied from interface:
ClassMappingFactory
- Creates an instance of the target type based on the source type.
Example:
DefaultMetaDataTransformerFactory
creates a MetaDataTransformer
for a given ValidationStrategy.
- Specified by:
create in interface ClassMappingFactory<Class,StorageManager>
- Parameters:
storageType - source object
- Returns:
- target object.
getNameMapperList
protected List<NameMapper<Class>> getNameMapperList()
- Specified by:
getNameMapperList in class AbstractNameMapperAwareFactory<Class>
setStorageManager
public void setStorageManager(Class storageType,
StorageManager storageManager,
boolean override)
- Description copied from interface:
StorageManagerHolder
- Define the storage manager for the given type.
- Specified by:
setStorageManager in interface StorageManagerHolder
- Parameters:
storageType - The identification for the storage manager, usually it is the storage-classstorageManager - The storageManager to use.override - use true to replace an existing storageManager and
false to use the manager only if there isn't an existing manager for the given type
getStorageManager
public StorageManager getStorageManager(Class type)
- Description copied from interface:
StorageManagerHolder
- Returns the storageManager for the given type.
- Specified by:
getStorageManager in interface StorageManagerHolder
- Parameters:
type - The identification for the storage manager, usually it is the storage-class
- Returns:
- the storageManager for the given type or null
Copyright © 2008-2012 The Apache Software Foundation. All Rights Reserved.