org.apache.commons.validator
public class FormSet extends Object implements Serializable
Form
s stored associated with a
Locale
based on the country, language, and variant specified.
Instances of this class are configured with a <formset> xml element.
Field Summary | |
---|---|
Map | constants
A Map of Constant s
using the name field of the Constant as the key. |
String | country
Country component of Locale (optional). |
Map | forms
A Map of Form s
using the name field of the Form as the key. |
String | language
Language component of Locale (required). |
boolean | processed
Whether or not the this FormSet was processed
for replacing variables in strings with their values. |
String | variant
Variant component of Locale (optional). |
Method Summary | |
---|---|
void | addConstant(Constant c)
Add a Constant (locale level). |
void | addConstant(String name, String value)
Add a Constant to the locale level. |
void | addConstantParam(String name, String value)
Add a Constant to the locale level. |
void | addForm(Form f)
Add a Form to the FormSet . |
String | getCountry()
Gets the equivalent of the country component of Locale . |
Form | getForm(Object key)
Retrieve a Form based on the form name. |
Form | getForm(String formName)
Retrieve a Form based on the form name. |
Map | getForms()
A Map of Form s is returned as an
unmodifiable Map with the key based on the form name. |
String | getLanguage()
Gets the equivalent of the language component of Locale . |
String | getVariant()
Gets the equivalent of the variant component of Locale . |
boolean | isProcessed()
Whether or not the this FormSet was processed
for replacing variables in strings with their values. |
void | process(Map globalConstants)
Processes all of the Form s. |
void | setCountry(String country)
Sets the equivalent of the country component of Locale . |
void | setLanguage(String language)
Sets the equivalent of the language component of Locale . |
void | setVariant(String variant)
Sets the equivalent of the variant component of Locale . |
String | toString()
Returns a string representation of the object. |
Map
of Constant
s
using the name field of the Constant
as the key.Locale
(optional).Map
of Form
s
using the name field of the Form
as the key.Locale
(required).FormSet
was processed
for replacing variables in strings with their values.Locale
(optional).Deprecated: Use addConstant(String, String) instead.
Add aConstant
(locale level).Constant
to the locale level.Deprecated: Use addConstant(String, String) instead.
Add aConstant
to the locale level.Form
to the FormSet
.Locale
.Deprecated: Use getForm(String) instead.
Retrieve aForm
based on the form name.Form
based on the form name.Map
of Form
s is returned as an
unmodifiable Map
with the key based on the form name.Locale
.Locale
.FormSet
was processed
for replacing variables in strings with their values.Deprecated: This method is called by the framework. It will be made protected in a future release. TODO
Processes all of theForm
s.Locale
.Locale
.Locale
.