org.apache.myfaces.extensions.validator.core
Class DefaultExtValCoreConfiguration

java.lang.Object
  extended by org.apache.myfaces.extensions.validator.core.ExtValCoreConfiguration
      extended by org.apache.myfaces.extensions.validator.core.DefaultExtValCoreConfiguration
All Implemented Interfaces:
ExtValModuleConfiguration

public class DefaultExtValCoreConfiguration
extends ExtValCoreConfiguration

Default ExtVal Core Module Configuration that retrieves most of the values from the Web.xml initialization parameters.

Since:
r4

Constructor Summary
DefaultExtValCoreConfiguration()
           
 
Method Summary
 boolean activateMarkupMetaData()
          Per default component initialization overrules properties of the component.
 boolean activateRequiredInitialization()
          Indicates if the ComponentInitializer's should mark UIComponents as 'required' if an equivalent constraint is hosted by the referenced property.
 Class<? extends Annotation> constraintSourceAnnotation()
          Returns a class of an annotation which should be used as ConstraintSource (use a custom implementation, if it is required to keep implementations independent of ExtVal)
 String customBasePackage()
          Define a new base package where custom versions of the ExtVal artifacts can be found.
 String customComponentInitializerClassName()
          Defines the name of a custom ComponentInitializer.
 String customComponentMetaDataExtractorClassName()
          Defines the class name of a custom MetaDataExtractor.
 String customComponentMetaDataExtractorFactoryClassName()
          Defines the name of a custom ComponentMetaDataExtractorFactory which creates MetaDataExtractors.
 String customFacesMessageFactoryClassName()
          Defines the name of a custom FacesMessageFactory which creates and converts FacesMessages (Default implementation: DefaultValidationParameterExtractorFactory.)
 String customInformationProviderBeanClassName()
          Defines the class name for a custom InformationProviderBean.
 String customMessageBundleBaseName()
          The name of the Resource bundle used for looking up resource keys of validation messages.
 String customMessageResolverFactoryClassName()
          Defines the name of a custom which is responsible for creating the MessageResolver for a given ValidationStrategy.
 String customMetaDataExtractionInterceptorClassName()
          Defines the name of a custom MetaDataExtractionInterceptor.
 String customMetaDataStorageFilterClassName()
          Defines the name of a custom MetaDataStorageFilter.
 String customMetaDataToValidationStrategyNameMapperClassName()
          Defines the name of the custom NameMapper that takes a constraint-key and points to the ValidationStrategy that is linked to it.
 String customMetaDataTransformerFactoryClassName()
          Defines the name of a custom which is responsible for creating a MetaDataTransformer for a given ValidationStrategy.
 String customPropertyValidationInterceptorClassName()
          Defines the name of a custom PropertyValidationInterceptor.
 String customStaticValidationStrategyMappingSource()
          Name of the optional property file which contains the mappings between ExtVal constraints and the ValidationStrategys for validating them.
 String customStorageManagerFactoryClassName()
          Defines the name of a custom which is responsible for creating the StorageManager for a given storage class.
 String customValidationExceptionInterceptorClassName()
          Defines the name of a custom ValidationExceptionInterceptor.
 String customValidationParameterExtractorClassName()
          Defines the class name of a custom ValidationParameterExtractor.
 String customValidationParameterExtractorFactoryClassName()
          Defines the name of a custom ValidationParameterExtractorFactory which creates ValidationParameterExtractors.
 String customValidationParameterFactoryClassName()
          Defines the name of a custom which is responsible for creating the final Validation Parameter class.
 String customValidationStrategyFactoryClassName()
          Defines the name of a custom which is responsible for creating a ValidationStrategy for a given metaData-key.
 String customValidationStrategyToMessageResolverNameMapperClassName()
          Defines the name of a custom NameMapper that takes a ValidationStrategy and points to the MessageResolver that is linked to it.
 String customValidationStrategyToMetaDataTransformerNameMapperClassName()
          Defines the name of the custom NameMapper that takes a ValidationStrategy and points to the MetaDataTransformer that is linked to it.
 boolean deactivateComponentInitialization()
          Defines if the mechanism of component initialization (before the rendering process) should be deactivated.
 boolean deactivateDefaultConvention()
          Indicates if ExtVal should deactivate the default convention.
 boolean deactivateDefaultNameMappers()
          Indicates if ExtVal should deactivate all the internal defined name mappers.
 boolean deactivateElResolver()
          Defines if ExtVal should fallback to an alternative (but deprecated) approach for inspecting EL-expressions.
 boolean deactivateRenderKitFactory()
          Defines if the default entry point of ExtVal should be deactivated.
 boolean deactivateRequiredAttributeSupport()
          Defines if ExtVal should reset the required attribute of a UIComponent after the decoding the component.
 boolean deactivateValidationParameters()
          Defines if the mechanism of generic validation parameters should be deactivated.
 Class<? extends ValidationParameter> disableClientSideValidationValidationParameter()
          Defines the validation parameter annotation which indicates that the validation information should not be transferred to the UIComponent.
 Class<? extends Annotation> ignoreConstraintSourceAnnotation()
          Returns a class of an annotation which should be used as IgnoreConstraintSource (use a custom implementation, if it is required to keep implementations independent of ExtVal)
 boolean interpretEmptyStringSubmittedValuesAsNull()
          Defines if ExtVal should convert empty strings to null (just for the validation process).
static void overruleActivateRequiredInitialization(Boolean value, boolean forceOverride)
          Module and add-on writers can use this method to overrule the value of the parameter activateRequiredInitialization.
static void overruleDeactivateRequiredAttributeSupport(Boolean value, boolean forceOverride)
          Module and add-on writers can use this method to overrule the value of the parameter deactivateRequiredAttributeSupport.
 ProjectStageResolver projectStageResolver()
          Defines the ProjectStageResolver that should be used by ExtVal.
 ProxyHelper proxyHelper()
          Defines the ProxyHelper that should be used by ExtVal.
 Class<? extends ExtValRendererProxy> rendererProxy()
          Defines an optional RendererProxy that should be used by ExtVal.
 Class<? extends Annotation> targetPropertyAnnotation()
          Returns a class of an annotation which should be used as TargetProperty (use a custom implementation, if it is required to keep implementations independent of ExtVal)
 Class<? extends Annotation> targetPropertyIdAnnotation()
          Returns a class of an annotation which should be used as TargetPropertyId (use a custom implementation, if it is required to keep implementations independent of ExtVal)
 boolean validateEmptyFields()
          Defines if ExtVal should validate empty fields.
 Class violationSeverity()
          Returns the class which should be used as violation severity.
 
Methods inherited from class org.apache.myfaces.extensions.validator.core.ExtValCoreConfiguration
get, use
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultExtValCoreConfiguration

public DefaultExtValCoreConfiguration()
Method Detail

customMessageBundleBaseName

public String customMessageBundleBaseName()
The name of the Resource bundle used for looking up resource keys of validation messages. Parameter taken from the Web.xml initialization parameter CUSTOM_MESSAGE_BUNDLE.

Specified by:
customMessageBundleBaseName in class ExtValCoreConfiguration
Returns:
Fully qualified name of a custom resource bundle.
See Also:
DefaultValidationErrorMessageResolver

customBasePackage

public String customBasePackage()
Define a new base package where custom versions of the ExtVal artifacts can be found. (Default value: org.apache.myfaces.extensions.validator.custom) Parameter taken from the Web.xml initialization parameter CUSTOM_BASE_PACKAGE.

Specified by:
customBasePackage in class ExtValCoreConfiguration
Returns:
package name
See Also:
InformationProviderBean.setupCustomizableInformation()

customInformationProviderBeanClassName

public String customInformationProviderBeanClassName()
Defines the class name for a custom InformationProviderBean. This class must extend InformationProviderBean. Parameter taken from the Web.xml initialization parameter CUSTOM_INFORMATION_PROVIDER_BEAN.

Specified by:
customInformationProviderBeanClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as InformationProviderBean

customComponentMetaDataExtractorClassName

public String customComponentMetaDataExtractorClassName()
Defines the class name of a custom MetaDataExtractor. (Default implementation: DefaultComponentMetaDataExtractor). Parameter taken from the Web.xml initialization parameter CUSTOM_COMPONENT_META_DATA_EXTRACTOR.

Specified by:
customComponentMetaDataExtractorClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as MetaDataExtractor.
See Also:
org.apache.myfaces.extensions.validator.core.metadata.extractor.DefaultComponentMetaDataExtractorFactory#createWith(java.util.Map)

customValidationParameterExtractorClassName

public String customValidationParameterExtractorClassName()
Defines the class name of a custom ValidationParameterExtractor. (Default implementation: DefaultValidationParameterExtractor. Parameter taken from the Web.xml initialization parameter CUSTOM_VALIDATION_PARAMETER_EXTRACTOR.

Specified by:
customValidationParameterExtractorClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as {@link org.apache.myfaces.extensions.validator.core.validation.parameter.ValidationParameterExtractor).
See Also:
DefaultValidationParameterExtractorFactory.create()

customStaticValidationStrategyMappingSource

public String customStaticValidationStrategyMappingSource()
Name of the optional property file which contains the mappings between ExtVal constraints and the ValidationStrategys for validating them. These mappings can be used to overrule all other configurations. Parameter taken from the Web.xml initialization parameter CUSTOM_STATIC_VALIDATION_STRATEGY_MAPPING.

Specified by:
customStaticValidationStrategyMappingSource in class ExtValCoreConfiguration
Returns:
Fully qualified name of the property file which contains the mappings.
See Also:
DefaultValidationStrategyFactory.initStaticMappings()

customComponentInitializerClassName

public String customComponentInitializerClassName()
Defines the name of a custom ComponentInitializer. Parameter taken from the Web.xml initialization parameter CUSTOM_COMPONENT_INITIALIZER.

Specified by:
customComponentInitializerClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as ComponentInitializer.
See Also:
ExtValContextInvocationOrderAwareInternals.lazyInitComponentInitializers()

customValidationExceptionInterceptorClassName

public String customValidationExceptionInterceptorClassName()
Defines the name of a custom ValidationExceptionInterceptor. Parameter taken from the Web.xml initialization parameter CUSTOM_VALIDATION_EXCEPTION_INTERCEPTOR.

Specified by:
customValidationExceptionInterceptorClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as ValidationExceptionInterceptor.
See Also:
ExtValContextInvocationOrderAwareInternals.lazyInitValidationExceptionInterceptors()

customPropertyValidationInterceptorClassName

public String customPropertyValidationInterceptorClassName()
Defines the name of a custom PropertyValidationInterceptor. Parameter taken from the Web.xml initialization parameter CUSTOM_PROPERTY_VALIDATION_INTERCEPTOR.

Specified by:
customPropertyValidationInterceptorClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as PropertyValidationInterceptor.
See Also:
ExtValContextInvocationOrderAwareInternals.lazyInitPropertyValidationInterceptors()

customMetaDataExtractionInterceptorClassName

public String customMetaDataExtractionInterceptorClassName()
Defines the name of a custom MetaDataExtractionInterceptor. Parameter taken from the Web.xml initialization parameter CUSTOM_META_DATA_EXTRACTION_INTERCEPTOR.

Specified by:
customMetaDataExtractionInterceptorClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as MetaDataExtractionInterceptor.
See Also:
ExtValContextInvocationOrderAwareInternals.lazyInitMetaDataExtractionInterceptors()

proxyHelper

public ProxyHelper proxyHelper()
Defines the ProxyHelper that should be used by ExtVal. (Default implementation: DefaultProxyHelper). The method should never return null. Parameter taken from the Web.xml initialization parameter CUSTOM_META_DATA_EXTRACTION_INTERCEPTOR. When no value is specified, the DefaultProxyHelper is returned.

Specified by:
proxyHelper in class ExtValCoreConfiguration
Returns:
The instance of the ProxyHelper that should be used.
See Also:
ProxyUtils.getProxyHelper()

projectStageResolver

public ProjectStageResolver projectStageResolver()
Defines the ProjectStageResolver that should be used by ExtVal. (Default implementation: DefaultProjectStageResolver If the method returns null, the project-stage 'Production' will be used. Returns always the DefaultProjectStageResolver.

Specified by:
projectStageResolver in class ExtValCoreConfiguration
Returns:
The instance of the ProjectStageResolver that should be used.
See Also:
ProjectStage.getCurrentProjectStage()

rendererProxy

public Class<? extends ExtValRendererProxy> rendererProxy()
Defines an optional RendererProxy that should be used by ExtVal. Returns the ExtValRendererProxy class which is configured in the global property of ExtVal. When no property defined, null is returned (which is correctly handled by the calling methods) or an exception can be thrown when the global property contains an invalid class name.

Specified by:
rendererProxy in class ExtValCoreConfiguration
Returns:
The instance of the RendererProxy that should be used.
See Also:
ExtValLazyRendererProxy.getLazyRenderer(), ExtValRendererWrapper.ExtValRendererWrapper(javax.faces.render.Renderer)

violationSeverity

public Class violationSeverity()
Returns the class which should be used as violation severity. (Default implementation: ViolationSeverity). Returns always the ViolationSeverity.

Specified by:
violationSeverity in class ExtValCoreConfiguration
Returns:
class which should be used as violation severity

customValidationStrategyToMessageResolverNameMapperClassName

public String customValidationStrategyToMessageResolverNameMapperClassName()
Defines the name of a custom NameMapper that takes a ValidationStrategy and points to the MessageResolver that is linked to it. (The class should implement the interface NameMapper.) Value taken from the Web.xml initialization parameter CUSTOM_VALIDATION_STRATEGY_TO_MESSAGE_RESOLVER_NAME_MAPPER.

Specified by:
customValidationStrategyToMessageResolverNameMapperClassName in class ExtValCoreConfiguration
Returns:
fully qualified class name of the custom NameMapper to retrieve MessageResolver name for a given ValidationStrategy.
See Also:
CustomConfiguredValidationStrategyToMsgResolverNameMapper.getCustomNameMapperClassName()

customMetaDataToValidationStrategyNameMapperClassName

public String customMetaDataToValidationStrategyNameMapperClassName()
Defines the name of the custom NameMapper that takes a constraint-key and points to the ValidationStrategy that is linked to it. (The class should implement the interface NameMapper.) Value taken from the Web.xml initialization parameter CUSTOM_META_DATA_TO_VALIDATION_STRATEGY_NAME_MAPPER.

Specified by:
customMetaDataToValidationStrategyNameMapperClassName in class ExtValCoreConfiguration
Returns:
fully qualified class name of the custom NameMapper to retrieve ValidationStrategy name for a given constraint-key.
See Also:
CustomConfiguredAnnotationToValidationStrategyNameMapper.CustomConfiguredAnnotationToValidationStrategyNameMapper()

customValidationStrategyToMetaDataTransformerNameMapperClassName

public String customValidationStrategyToMetaDataTransformerNameMapperClassName()
Defines the name of the custom NameMapper that takes a ValidationStrategy and points to the MetaDataTransformer that is linked to it. (The class should implement the interface NameMapper.) Value taken from the Web.xml initialization parameter CUSTOM_VALIDATION_STRATEGY_TO_META_DATA_TRANSFORMER_NAME_MAPPER.

Specified by:
customValidationStrategyToMetaDataTransformerNameMapperClassName in class ExtValCoreConfiguration
Returns:
fully qualified class name of the custom NameMapper to retrieve MetaDataTransformer name for a given ValidationStrategy.
See Also:
CustomConfiguredValidationStrategyToMetaDataTransformerNameMapper.getCustomNameMapperClassName()

customMetaDataStorageFilterClassName

public String customMetaDataStorageFilterClassName()
Defines the name of a custom MetaDataStorageFilter. Value taken from the Web.xml initialization parameter CUSTOM_META_DATA_STORAGE_FILTER.

Specified by:
customMetaDataStorageFilterClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as MetaDataStorageFilter.
See Also:
DefaultMetaDataStorage.initFilters()

customValidationStrategyFactoryClassName

public String customValidationStrategyFactoryClassName()
Defines the name of a custom which is responsible for creating a ValidationStrategy for a given metaData-key. (Default implementation: DefaultValidationStrategyFactory.) Value taken from the Web.xml initialization parameter CUSTOM_VALIDATION_STRATEGY_FACTORY.

Specified by:
customValidationStrategyFactoryClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as ClassMappingFactory
See Also:
DefaultFactoryFinder.createValidationStrategyFactory()

customMessageResolverFactoryClassName

public String customMessageResolverFactoryClassName()
Defines the name of a custom which is responsible for creating the MessageResolver for a given ValidationStrategy. (Default implementation: DefaultMessageResolverFactory.) Value taken from the Web.xml initialization parameter CUSTOM_MESSAGE_RESOLVER_FACTORY.

Specified by:
customMessageResolverFactoryClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as ClassMappingFactory
See Also:
DefaultFactoryFinder.createMessageResolverFactory()

customComponentMetaDataExtractorFactoryClassName

public String customComponentMetaDataExtractorFactoryClassName()
Defines the name of a custom ComponentMetaDataExtractorFactory which creates MetaDataExtractors. (Default implementation: DefaultComponentMetaDataExtractorFactory .) Value taken from the Web.xml initialization parameter CUSTOM_COMPONENT_META_DATA_EXTRACTOR_FACTORY.

Specified by:
customComponentMetaDataExtractorFactoryClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as ComponentMetaDataExtractorFactory
See Also:
DefaultFactoryFinder.createComponentMetaDataExtractorFactory()

customValidationParameterExtractorFactoryClassName

public String customValidationParameterExtractorFactoryClassName()
Defines the name of a custom ValidationParameterExtractorFactory which creates ValidationParameterExtractors. (Default implementation: DefaultValidationParameterExtractorFactory.) Value taken from the Web.xml initialization parameter CUSTOM_VALIDATION_PARAMETER_EXTRACTOR_FACTORY.

Specified by:
customValidationParameterExtractorFactoryClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as ValidationParameterExtractorFactory
See Also:
DefaultFactoryFinder.createValidationParameterExtractorFactory()

customValidationParameterFactoryClassName

public String customValidationParameterFactoryClassName()
Defines the name of a custom which is responsible for creating the final Validation Parameter class. (Default implementation: DefaultValidationParameterFactory.) Value taken from the Web.xml initialization parameter CUSTOM_VALIDATION_PARAMETER_FACTORY.

Specified by:
customValidationParameterFactoryClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as ClassMappingFactory
See Also:
DefaultFactoryFinder.createValidationParameterFactory()

customMetaDataTransformerFactoryClassName

public String customMetaDataTransformerFactoryClassName()
Defines the name of a custom which is responsible for creating a MetaDataTransformer for a given ValidationStrategy. (Default implementation: DefaultMetaDataTransformerFactory.) Value taken from the Web.xml initialization parameter CUSTOM_META_DATA_TRANSFORMER_FACTORY.

Specified by:
customMetaDataTransformerFactoryClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as ClassMappingFactory
See Also:
DefaultFactoryFinder.createMetaDataTransformerFactory()

customStorageManagerFactoryClassName

public String customStorageManagerFactoryClassName()
Defines the name of a custom which is responsible for creating the StorageManager for a given storage class. (Default implementation: DefaultStorageManagerFactory.) Value taken from the Web.xml initialization parameter CUSTOM_STORAGE_MANAGER_FACTORY.

Specified by:
customStorageManagerFactoryClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of implementation of a ClassMappingFactory.
See Also:
DefaultFactoryFinder.createStorageManagerFactory()

customFacesMessageFactoryClassName

public String customFacesMessageFactoryClassName()
Defines the name of a custom FacesMessageFactory which creates and converts FacesMessages (Default implementation: DefaultValidationParameterExtractorFactory.) Value taken from the Web.xml initialization parameter CUSTOM_FACES_MESSAGE_FACTORY.

Specified by:
customFacesMessageFactoryClassName in class ExtValCoreConfiguration
Returns:
Fully qualified class name of the class to be used as FacesMessageFactory
See Also:
DefaultFactoryFinder.createFacesMessageFactory()

constraintSourceAnnotation

public Class<? extends Annotation> constraintSourceAnnotation()
Returns a class of an annotation which should be used as ConstraintSource (use a custom implementation, if it is required to keep implementations independent of ExtVal) Returns the ConstraintSource class as annotation for the Constraint Source feature.

Specified by:
constraintSourceAnnotation in class ExtValCoreConfiguration
Returns:
Annotation class of the alternative implementation
See Also:
ConstraintSourceUtils.findMappedClass(org.apache.myfaces.extensions.validator.core.storage.PropertyStorage, java.lang.Class, java.lang.String)

ignoreConstraintSourceAnnotation

public Class<? extends Annotation> ignoreConstraintSourceAnnotation()
Returns a class of an annotation which should be used as IgnoreConstraintSource (use a custom implementation, if it is required to keep implementations independent of ExtVal) Returns the IgnoreConstraintSource class as annotation for the ignore feature of the Constraint Source.

Specified by:
ignoreConstraintSourceAnnotation in class ExtValCoreConfiguration
Returns:
Annotation class of the alternative implementation
See Also:
ConstraintSourceUtils.getIgnoreConstraintSourceAnnotationImplementation()

targetPropertyAnnotation

public Class<? extends Annotation> targetPropertyAnnotation()
Returns a class of an annotation which should be used as TargetProperty (use a custom implementation, if it is required to keep implementations independent of ExtVal) Returns the TargetProperty class as annotation for the Constraint Source target property feature.

Specified by:
targetPropertyAnnotation in class ExtValCoreConfiguration
Returns:
Annotation class of the alternative implementation
See Also:
ConstraintSourceUtils.getTargetPropertyAnnotationImplementation()

targetPropertyIdAnnotation

public Class<? extends Annotation> targetPropertyIdAnnotation()
Returns a class of an annotation which should be used as TargetPropertyId (use a custom implementation, if it is required to keep implementations independent of ExtVal) Returns the TargetPropertyId class as annotation for the Constraint Source target property feature.

Specified by:
targetPropertyIdAnnotation in class ExtValCoreConfiguration
Returns:
Annotation class of the alternative implementation
See Also:
ConstraintSourceUtils.getTargetPropertyIdAnnotationImplementation()

disableClientSideValidationValidationParameter

public Class<? extends ValidationParameter> disableClientSideValidationValidationParameter()
Defines the validation parameter annotation which indicates that the validation information should not be transferred to the UIComponent. Returns the DisableClientSideValidation class as indicator for this feature.

Specified by:
disableClientSideValidationValidationParameter in class ExtValCoreConfiguration
Returns:
Validation parameter annotation for indicating that no validation information needs to be set on the ui-component.
See Also:
ExtValStartupListener.initDisableClientSideValidationKey()

activateRequiredInitialization

public boolean activateRequiredInitialization()
Indicates if the ComponentInitializer's should mark UIComponents as 'required' if an equivalent constraint is hosted by the referenced property. First a global parameter is checked to see if the Module or Add-on hasn't overruled the value of the Web.xml initialization parameter ACTIVATE_REQUIRED_INITIALIZATION. If overruled, this value is taken, otherwise the initialization parameter value. By default, the method return false if there are no values specified.

Specified by:
activateRequiredInitialization in class ExtValCoreConfiguration
Returns:
true if the required attribute should be honored, false otherwise.
See Also:
org.apache.myfaces.extensions.validator.core.initializer.component.AbstractHtmlCoreComponentsComponentInitializer#configureComponent(javax.faces.context.FacesContext, javax.faces.component.UIComponent, java.util.Map)

overruleActivateRequiredInitialization

public static void overruleActivateRequiredInitialization(Boolean value,
                                                          boolean forceOverride)
Module and add-on writers can use this method to overrule the value of the parameter activateRequiredInitialization. it is also useful for them to specify a certain parameter value without the need for a web.xml initialization parameter.

Parameters:
value - The value we want to give the parameter
forceOverride - do we force overriding of another value set by a call to this overrule method.

deactivateDefaultConvention

public boolean deactivateDefaultConvention()
Indicates if ExtVal should deactivate the default convention. Value taken from the Web.xml initialization parameter DEACTIVATE_DEFAULT_CONVENTION.

Specified by:
deactivateDefaultConvention in class ExtValCoreConfiguration
Returns:
true if the default convention should be deactivated, false otherwise

deactivateDefaultNameMappers

public boolean deactivateDefaultNameMappers()
Indicates if ExtVal should deactivate all the internal defined name mappers. (Be aware that ExtVal will fail, if no alternatives are defined.) Value taken from the Web.xml initialization parameter DEACTIVATE_DEFAULT_NAME_MAPPERS.

Specified by:
deactivateDefaultNameMappers in class ExtValCoreConfiguration
Returns:
true when we want to deactivate internal defined name mappers.
See Also:
ExtValStartupListener.initNameMappers()

deactivateElResolver

public boolean deactivateElResolver()
Defines if ExtVal should fallback to an alternative (but deprecated) approach for inspecting EL-expressions. Value taken from the Web.xml initialization parameter DEACTIVATE_EL_RESOLVER.

Specified by:
deactivateElResolver in class ExtValCoreConfiguration
Returns:
true when we want to deactivate internal EL Resolver.
See Also:
DefaultELHelper

deactivateComponentInitialization

public boolean deactivateComponentInitialization()
Defines if the mechanism of component initialization (before the rendering process) should be deactivated. Value taken from the Web.xml initialization parameter DEACTIVATE_COMPONENT_INITIALIZATION.

Specified by:
deactivateComponentInitialization in class ExtValCoreConfiguration
Returns:
true if UIComponents should not be initialized by ExtVal, false otherwise.
See Also:
ExtValContextInternals.isComponentInitializationActivated(), AbstractValidationInterceptor.isComponentInitializationDeactivated()

deactivateValidationParameters

public boolean deactivateValidationParameters()
Defines if the mechanism of generic validation parameters should be deactivated. Value taken from the Web.xml initialization parameter DEACTIVATE_VALIDATION_PARAMETERS.

Specified by:
deactivateValidationParameters in class ExtValCoreConfiguration
Returns:
true if validation parameter extraction should be skipped, false otherwise
See Also:
ExtValUtils.getValidationParameterExtractor()

deactivateRenderKitFactory

public boolean deactivateRenderKitFactory()
Defines if the default entry point of ExtVal should be deactivated. (Attention: in case of mojarra you have to use the vm-parameter: org.apache.myfaces.extensions.validator.DEACTIVATE_RENDER_KIT_FACTORY) Value taken from the Web.xml initialization parameter DEACTIVATE_RENDER_KIT_FACTORY.

Specified by:
deactivateRenderKitFactory in class ExtValCoreConfiguration
Returns:
true for deactivating ExtVal, false otherwise
See Also:
ExtValRenderKitFactory.checkRenderKitFactoryDeactivation()

deactivateRequiredAttributeSupport

public boolean deactivateRequiredAttributeSupport()
Defines if ExtVal should reset the required attribute of a UIComponent after the decoding the component. (It's needed for special use-cases.) First a global parameter is checked to see if some Module or Add-on hasn't overruled the value of the Web.xml initialization parameter DEACTIVATE_REQUIRED_ATTRIBUTE_SUPPORT. If overruled, this value is taken, otherwise the initialization parameter value. By default, the method return false if there are no values specified.

Specified by:
deactivateRequiredAttributeSupport in class ExtValCoreConfiguration
Returns:
true if ExtVal should set the required attribute to false, false otherwise
See Also:
ExtValUtils.isRequiredResetActivated()

overruleDeactivateRequiredAttributeSupport

public static void overruleDeactivateRequiredAttributeSupport(Boolean value,
                                                              boolean forceOverride)
Module and add-on writers can use this method to overrule the value of the parameter deactivateRequiredAttributeSupport. It is also useful for them to specify a certain parameter value without the need for a web.xml initialization parameter.

Parameters:
value - The value we want to give the parameter
forceOverride - do we force overriding of another value set by a call to this overrule method.

interpretEmptyStringSubmittedValuesAsNull

public boolean interpretEmptyStringSubmittedValuesAsNull()
Defines if ExtVal should convert empty strings to null (just for the validation process). (Introduced by JSF 2.0) Compared to std. JSF it's activated by default! Value taken from the Web.xml initialization (JSF 2) parameter avax.faces.INTERPRET_EMPTY_STRING_SUBMITTED_VALUES_AS_NULL.

Specified by:
interpretEmptyStringSubmittedValuesAsNull in class ExtValCoreConfiguration
Returns:
false for using the default behavior of JSF 2.0

validateEmptyFields

public boolean validateEmptyFields()
Defines if ExtVal should validate empty fields. Please also have a look at the NullValueAwareValidationStrategy annotation. (Introduced by JSF 2.0) Compared to std. JSF it's activated by default! Value taken from the Web.xml initialization (JSF 2) parameter javax.faces.VALIDATE_EMPTY_FIELDS.

Specified by:
validateEmptyFields in class ExtValCoreConfiguration
Returns:
false for using the default behavior of JSF 2.0

activateMarkupMetaData

public boolean activateMarkupMetaData()
Per default component initialization overrules properties of the component. With activating markup meta-data it's possible to overrule the meta-data of the constraints with the meta-data of the component. Value taken from the Web.xml initialization parameter ACTIVATE_MARKUP_META_DATA.

Specified by:
activateMarkupMetaData in class ExtValCoreConfiguration
Returns:
true to overrule constraint meta-data with meta-data provided by the component, false otherwise


Copyright © 2008-2012 The Apache Software Foundation. All Rights Reserved.