| org.iscreen.impl.xml.XmlServiceFactory org.iscreen.mvel.MvelXmlServiceFactory
MvelXmlServiceFactory | public class MvelXmlServiceFactory extends XmlServiceFactory (Code) | | This factory constructs a ValidationService based upon an XML
configuration (via file or String, etc.). This ValidationFactory
supports XML files that use MVEL.
author: Shellman, Dan |
Method Summary | |
public void | addValidationSetToSet(String setId, String setRefId, boolean failFastFlag, String name, String ifExp, String iterateExp, String mapExp) Adds a validation set reference call to a validation set. | public void | addValidatorToSet(String setId, String globalDefaultResource, String defaultResource, String validatorRef, boolean failFastFlag, String validatorName, XmlConfigLabel label, XmlConfigDoc doc, Set mappings, Set constraints, Set failures) Adds a 'use-validator' to a Validation Set. | protected void | configureValidator(MvelConfiguredValidator validator, String globalDefaultResource, String defaultResource, XmlConfigLabel label, XmlConfigDoc doc, Set mappings, Set constraints, Set failures) Handles the actual configuration of a Validator, whether via registration
or by adding one to a Validation Set. | public MvelConfiguredValidator | getValidator(String id) Retrieves a MvelConfiguredValidator with the given id. | public void | registerService(String serviceId, Object service) Registers a service with the factory. | public void | registerValidationSet(String id) Registers a Validation Set. | public void | registerValidator(String globalDefaultResource, String id, String ref, String className, String defaultResource, XmlConfigLabel label, XmlConfigDoc doc, Set mappings, Set constraints, Set failures) Registers an individual Validator configuration. |
MvelXmlServiceFactory | public MvelXmlServiceFactory()(Code) | | Default constructor.
|
addValidationSetToSet | public void addValidationSetToSet(String setId, String setRefId, boolean failFastFlag, String name, String ifExp, String iterateExp, String mapExp)(Code) | | Adds a validation set reference call to a validation set.
Parameters: setId - The id of the containing Validation Set. Parameters: setRefId - The id of the Validation Set being referenced. Parameters: failFastFlag - Whether to continue validations if the setreports a failure. Parameters: ifExp - Whether to execute the validations in the referenced set. Parameters: iterateExp - Whether to iterate over the objects being mappedand validate each one. Parameters: mapExp - The mapping expression. |
addValidatorToSet | public void addValidatorToSet(String setId, String globalDefaultResource, String defaultResource, String validatorRef, boolean failFastFlag, String validatorName, XmlConfigLabel label, XmlConfigDoc doc, Set mappings, Set constraints, Set failures)(Code) | | Adds a 'use-validator' to a Validation Set. The 'use-validator' must
reference a Validator.
Parameters: setId - The Validation Set id. Parameters: globalDefaultResource - The configuration file's default resource(can be null/empty). Parameters: defaultResource - The Validation Set's default resource (optional). Parameters: validatorRef - The reference to a Validator (required). Parameters: failFastFlag - Whether to stop validations if this validator fails. Parameters: label - The label for this validator. Parameters: doc - Documentation for this use of the validator. Parameters: mappings - The mappings for this validator. Parameters: constraints - The constraints for this validator. Parameters: failures - The failures for this validator. |
getValidator | public MvelConfiguredValidator getValidator(String id)(Code) | | Retrieves a MvelConfiguredValidator with the given id. If one has not
been previously registered, then create a blank one.
Parameters: id - The Validator's id. Returns a Validator with the given id. |
registerService | public void registerService(String serviceId, Object service)(Code) | | Registers a service with the factory. This service can then be
referenced by validators via configuration.
Parameters: serviceId - The service id Parameters: service - The service |
registerValidationSet | public void registerValidationSet(String id)(Code) | | Registers a Validation Set.
Parameters: id - The validation set's unique id. |
registerValidator | public void registerValidator(String globalDefaultResource, String id, String ref, String className, String defaultResource, XmlConfigLabel label, XmlConfigDoc doc, Set mappings, Set constraints, Set failures)(Code) | | Registers an individual Validator configuration. This will create
a configured Validator that can be referenced by other Validators or
by adding a Validator to a Validation Set.
Parameters: globalDefaultResource - The resource id, when all else fails. Parameters: id - The unique id of the Validator Parameters: ref - The unique id of the Validator this Validator references.This can be null and is optional. Parameters: className - The class name of the Validator (optional, but ifthere MUST be a valid ref). Parameters: defaultResource - The resource id if no id is defined locally. Parameters: label - The Label for the Validator. This is optional. Parameters: doc - Documentation for this use of the validator. Parameters: mappings - The Set of mappings (can't be null, but can be empty). Parameters: constraints - The Set of constraints (can't be null, but can be empty). Parameters: failures - The Set of failures (can't be null, but can be empty). |
Methods inherited from org.iscreen.impl.xml.XmlServiceFactory | abstract public void addValidationSetToSet(String setId, String setRefId, boolean failFastFlag, String name, String ifExp, String iterateExp, String mapExp)(Code)(Java Doc) abstract public void addValidatorToSet(String setId, String globalDefaultResource, String defaultResource, String validatorRef, boolean failFastFlag, String validatorName, XmlConfigLabel label, XmlConfigDoc doc, Set mappings, Set constraints, Set failures)(Code)(Java Doc) public ConfiguredResource getResource(String id)(Code)(Java Doc) public ConfiguredResource getResource(String id1, String id2, String id3)(Code)(Java Doc) public ValidationService getValidationService(String serviceName)(Code)(Java Doc) protected void loadConfig()(Code)(Java Doc) public void registerInclude(String location)(Code)(Java Doc) public void registerResource(String id, String ref, Set messages, Set resourceFiles)(Code)(Java Doc) public void registerService(String serviceId, Object service)(Code)(Java Doc) abstract public void registerValidationSet(String id)(Code)(Java Doc) abstract public void registerValidator(String globalDefaultResource, String id, String ref, String className, String defaultResource, XmlConfigLabel label, XmlConfigDoc doc, Set mappings, Set constraints, Set failures)(Code)(Java Doc)
|
|
|