| org.apache.tapestry.services.FieldValidatorSource
All known Subclasses: org.apache.tapestry.internal.services.FieldValidatorSourceImpl,
FieldValidatorSource | public interface FieldValidatorSource (Code) | | Used to create
FieldValidator s for a particular
Field component.
|
Method Summary | |
FieldValidator | createValidator(Field field, String validatorType, String constraintValue) Creates the validator. | FieldValidator | createValidator(Field field, String validatorType, String constraintValue, String overrideId, Messages overrideMessages, Locale locale) Full featured version of
FieldValidatorSource.createValidator(Field,String,String) used in situations
where the container of the field is not necesarrilly the place to look for override messages,
and the id of the field is not the key to use when checking. | FieldValidator | createValidators(Field field, String specification) Creates a set of validators. |
createValidator | FieldValidator createValidator(Field field, String validatorType, String constraintValue)(Code) | | Creates the validator. The error message associated with the field validator usually comes
from the
ValidationMessagesSource (using the validator's
Validator.getMessageKey message key ). However, if the container component of the
field defines a message key id-validator
(where id is the simple id of the field component, and validator is the validatorType), then that
message is used instead. This allows you to override the message for a particular validation of a particular field.
Parameters: field - the field for which a validator is to be created Parameters: validatorType - used to select the Validator that forms the core of theFieldValidator Parameters: constraintValue - a value used to configure the validator, or null if the validator is notconfigurarable the field validator for the field |
createValidator | FieldValidator createValidator(Field field, String validatorType, String constraintValue, String overrideId, Messages overrideMessages, Locale locale)(Code) | | Full featured version of
FieldValidatorSource.createValidator(Field,String,String) used in situations
where the container of the field is not necesarrilly the place to look for override messages,
and the id of the field is not the key to use when checking. The
BeanEditForm is an
example of this.
Parameters: field - the field for which a validator is to be created Parameters: validatorType - used to select the Validator that forms the core of theFieldValidator Parameters: constraintValue - a value used to configure the validator, or null if the validator is notconfigurable Parameters: overrideId - the base id used when searching for validator message overrides (this wouldnormally be the field component's simple id) Parameters: overrideMessages - the message catalog to search for override messages (this would normally be thecatalog for the container of the field component) Parameters: locale - locale used when retrieving default validation messages from theValidationMessagesSource the field validator for the field |
createValidators | FieldValidator createValidators(Field field, String specification)(Code) | | Creates a set of validators. The specification is a string used to identify and configure the
individual validators. The specification is a comma-separated list of terms. Each term is a
validator type name and an optional constraint value (seperated by an equals sign).
Parameters: field - Parameters: specification - a composite field validator |
|
|