org.apache.myfaces.extensions.validator.beanval
Class ExtValBeanValidationModuleConfiguration

java.lang.Object
  extended by org.apache.myfaces.extensions.validator.beanval.ExtValBeanValidationModuleConfiguration
All Implemented Interfaces:
ExtValModuleConfiguration
Direct Known Subclasses:
DefaultExtValBeanValidationModuleConfiguration

public abstract class ExtValBeanValidationModuleConfiguration
extends Object
implements ExtValModuleConfiguration

ExtVal Core Module configuration. 'custom' as prefix is used for 'optional' configurations. That means if a method returns null ExtVal uses a different approach to find an implementation e.g. via a naming convention -> all other methods aren't allowed to return null if there is no additional rule.

Since:
r4

Constructor Summary
protected ExtValBeanValidationModuleConfiguration()
           
 
Method Summary
abstract  ExtValBeanValidationContext customExtValBeanValidationContext()
          Allows to customize the ExtValBeanValidationContext
abstract  javax.validation.ValidatorFactory customValidatorFactory()
          Allows to customize the ValidatorFactory
static ExtValBeanValidationModuleConfiguration get()
          Returns the configuration for the core-module stored in the context.
static boolean use(ExtValBeanValidationModuleConfiguration config, boolean forceOverride)
          Sets a new configuration for the core-module
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExtValBeanValidationModuleConfiguration

protected ExtValBeanValidationModuleConfiguration()
Method Detail

get

public static ExtValBeanValidationModuleConfiguration get()
Returns the configuration for the core-module stored in the context. If this doesn't exists (usually a startup-listener registers a (custom) implementation), it returns a new instance of the default implementation.

Returns:
The active ExtVal Core Module Configuration

use

public static boolean use(ExtValBeanValidationModuleConfiguration config,
                          boolean forceOverride)
Sets a new configuration for the core-module

Parameters:
config - The new configuration for the core-module
forceOverride - use true to replace an existing configuration
Returns:
true if the new config was registered successfully

customValidatorFactory

public abstract javax.validation.ValidatorFactory customValidatorFactory()
Allows to customize the ValidatorFactory

Returns:
an instance of a custom ValidatorFactory, null otherwise

customExtValBeanValidationContext

public abstract ExtValBeanValidationContext customExtValBeanValidationContext()
Allows to customize the ExtValBeanValidationContext

Returns:
an instance of a custom ExtValBeanValidationContext, null otherwise


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