Package org.apache.commons.validator
Class FormSetFactory
- java.lang.Object
-
- org.apache.commons.digester.AbstractObjectCreationFactory
-
- org.apache.commons.validator.FormSetFactory
-
- All Implemented Interfaces:
org.apache.commons.digester.ObjectCreationFactory
public class FormSetFactory extends org.apache.commons.digester.AbstractObjectCreationFactory
Factory class used by Digester to create FormSet's.- Since:
- Validator 1.2
- Version:
- $Revision: 478334 $ $Date: 2006-11-22 21:31:54 +0000 (Wed, 22 Nov 2006) $
-
-
Field Summary
Fields Modifier and Type Field Description private org.apache.commons.logging.Log
log
Logging
-
Constructor Summary
Constructors Constructor Description FormSetFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private FormSet
createFormSet(ValidatorResources resources, java.lang.String language, java.lang.String country, java.lang.String variant)
Create or retrieve aFormSet
based on the language, country and variant.java.lang.Object
createObject(org.xml.sax.Attributes attributes)
Create or retrieve aFormSet
for the specified attributes.private org.apache.commons.logging.Log
getLog()
Accessor method for Log instance.
-
-
-
Method Detail
-
createObject
public java.lang.Object createObject(org.xml.sax.Attributes attributes) throws java.lang.Exception
Create or retrieve a
FormSet
for the specified attributes.- Specified by:
createObject
in interfaceorg.apache.commons.digester.ObjectCreationFactory
- Specified by:
createObject
in classorg.apache.commons.digester.AbstractObjectCreationFactory
- Parameters:
attributes
- The sax attributes for the formset element.- Returns:
- The FormSet for a locale.
- Throws:
java.lang.Exception
- If an error occurs creating the FormSet.
-
createFormSet
private FormSet createFormSet(ValidatorResources resources, java.lang.String language, java.lang.String country, java.lang.String variant) throws java.lang.Exception
Create or retrieve a
FormSet
based on the language, country and variant.- Parameters:
resources
- The validator resources.language
- The locale's language.country
- The locale's country.variant
- The locale's language variant.- Returns:
- The FormSet for a locale.
- Throws:
java.lang.Exception
- Since:
- Validator 1.2
-
getLog
private org.apache.commons.logging.Log getLog()
Accessor method for Log instance. The Log instance variable is transient and accessing it through this method ensures it is re-initialized when this instance is de-serialized.- Returns:
- The Log instance.
-
-