org.apache.myfaces.extensions.validator.core.validation.strategy.mapper
Class AnnotationToValidationStrategyBeanNameMapper
java.lang.Object
org.apache.myfaces.extensions.validator.core.validation.strategy.mapper.AbstractMetaDataToValidationStrategyNameMapper
org.apache.myfaces.extensions.validator.core.validation.strategy.mapper.AnnotationToValidationStrategyBeanNameMapper
- All Implemented Interfaces:
- NameMapper<String>
@InvocationOrder(value=500)
public class AnnotationToValidationStrategyBeanNameMapper
- extends AbstractMetaDataToValidationStrategyNameMapper
Name Mapper which delegates the name mapping, extract the name and convert it to a bean name + prefix
target: configure a validation strategy via a managed bean facility -> allows to inject other beans
instead of api calls + hardcoded bean names
allowed bean scopes:
the validation strategy is stateless: application/singleton
the validation strategy is stateful: none/prototype
don't use the session or a conversation scope
- Since:
- 1.x.1
Method Summary |
String |
createName(String source)
Returns the name of the target resource for the given source or null if the implementations isn't responsible
to map the given instance. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PREFIX_FOR_BEAN_MAPPING
public static final String PREFIX_FOR_BEAN_MAPPING
- See Also:
- Constant Field Values
AnnotationToValidationStrategyBeanNameMapper
public AnnotationToValidationStrategyBeanNameMapper(NameMapper<String> nameMapper)
createName
public String createName(String source)
- Description copied from interface:
NameMapper
- Returns the name of the target resource for the given source or null if the implementations isn't responsible
to map the given instance.
- Parameters:
source
- Object for which the name must be created.
- Returns:
- name of the target resource or null if the source isn't supported.
Copyright © 2008-2012 The Apache Software Foundation. All Rights Reserved.