org.apache.tapestry5.services

## Interface FieldValidatorDefaultSource

- All Known Implementing Classes:
    BeanFieldValidatorDefaultSource, FieldValidatorDefaultSourceImpl

      public interface FieldValidatorDefaultSource

  For a particular field, generates the default validation for the field, in accordance with a number of factors and contributions.

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `FieldValidator` | `createDefaultValidator(ComponentResources resources, String parameterName)` A convenience for the full version; assumes that the resources are associated with a `Field`.
    `FieldValidator` | `createDefaultValidator(Field field, String overrideId, Messages overrideMessages, Locale locale, Class propertyType, AnnotationProvider propertyAnnotations)` Analyzes the property type and property annotations to determine the default set of validations for the property, which are wrapped to form a `FieldValidator` for a field.

- - ### Method Detail

    - #### createDefaultValidator

          FieldValidator createDefaultValidator(Field field,
                                                String overrideId,
                                                Messages overrideMessages,
                                                Locale locale,
                                                Class propertyType,
                                                AnnotationProvider propertyAnnotations)

      Analyzes the property type and property annotations to determine the default set of validations for the property, which are wrapped to form a `FieldValidator` for a field.
      Parameters:
        `field` - Field component for which a validator is being created
        `overrideId` - the id of the component, used to locate related messages for labels and errors
        `overrideMessages` - where to search for label and error messages
        `locale` - locale used for locating messages
        `propertyType` - type of property bound to the editting parameter of the field (typically, the parameter named "value").
        `propertyAnnotations` - source of annotations for the property being editted
      Returns:
        a validator reflecting all default validations for the field

    - #### createDefaultValidator

          FieldValidator createDefaultValidator(ComponentResources resources,
                                                String parameterName)

      A convenience for the full version; assumes that the resources are associated with a `Field`.
      Parameters:
        `resources` -
        `parameterName` -
      Returns:
        a validator reflecting all default validations for the field

${project.version} - Copyright © 2003-2015 The Apache Software Foundation.