|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.struts.action.ActionForm
org.apache.struts.action.DynaActionForm
org.apache.struts.validator.DynaValidatorForm
org.apache.struts.validator.DynaValidatorActionForm
jp.terasoluna.fw.web.struts.form.DynaValidatorActionFormEx
public class DynaValidatorActionFormEx
Dynamic action form class.
DynaValidatorActionFormEx enables to generate the action form dynamically by setting the configuration information in Struts configuration file (struts-config.xml).
Example of creating action form in Struts configuration file (struts-config.xml)
<form-beans>
<form-bean
name="_validateSampleForm"
type="jp.terasoluna.fw.web.thin.form.DynaValidatorActionFormEx">
<form-property name="companyId" type="java.lang.String" />
<form-property name="userId" type="java.lang.String" />
<form-property name="password" type="java.lang.String" />
<form-property name="longName" type="java.lang.String" />
<form-property name="codeArray" type="java.util.ArrayList" />
</form-bean>
</form-beans>
Specify form name in name attribute of <form-bean>
tag and class name in the type attribute.
ValidatorActionFormEx,
RequestProcessorEx,
Resetter,
ResetterPlugIn,
FieldChecksEx,
BLogicMapper,
Serialized Form| Field Summary | |
|---|---|
private static org.apache.commons.logging.Log |
log
Log class. |
private boolean |
modified
Field value change flag. |
private static long |
serialVersionUID
Serial version ID |
| Fields inherited from class org.apache.struts.validator.DynaValidatorForm |
|---|
page, validatorResults |
| Fields inherited from class org.apache.struts.action.DynaActionForm |
|---|
dynaClass, dynaValues |
| Fields inherited from class org.apache.struts.action.ActionForm |
|---|
multipartRequestHandler, servlet |
| Constructor Summary | |
|---|---|
DynaValidatorActionFormEx()
|
|
| Method Summary | |
|---|---|
java.lang.Object |
get(java.lang.String name,
int index)
Fetches the indexed property. |
int |
getIndexCount(java.lang.String fieldName)
Fetches the record count of specified field. |
java.lang.Object |
getIndexedValue(java.lang.String name,
int index)
Fetches the indexed property. |
boolean |
isModified()
Fetches field value change flag. |
void |
reset(org.apache.struts.action.ActionMapping mapping,
javax.servlet.http.HttpServletRequest request)
Resets the field value of action form. |
void |
set(java.lang.String name,
int index,
java.lang.Object value)
Sets the indexed property. |
void |
setIndexedValue(java.lang.String name,
int index,
java.lang.Object value)
Sets indexed property. |
void |
setModified(boolean modified)
Sets ield value change flag. |
| Methods inherited from class org.apache.struts.validator.DynaValidatorActionForm |
|---|
getValidationKey |
| Methods inherited from class org.apache.struts.validator.DynaValidatorForm |
|---|
getPage, getResultValueMap, getValidatorResults, setPage, setPageFromDynaProperty, setValidatorResults, validate |
| Methods inherited from class org.apache.struts.action.DynaActionForm |
|---|
contains, get, get, getDynaClass, getDynaProperty, getMap, getString, getStrings, initialize, initialize, isDynaAssignable, remove, reset, set, set, toString |
| Methods inherited from class org.apache.struts.action.ActionForm |
|---|
getMultipartRequestHandler, getServlet, getServletWrapper, setMultipartRequestHandler, setServlet, validate |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.apache.commons.beanutils.DynaBean |
|---|
contains, get, get, getDynaClass, remove, set, set |
| Field Detail |
|---|
private static final long serialVersionUID
private static org.apache.commons.logging.Log log
private boolean modified
| Constructor Detail |
|---|
public DynaValidatorActionFormEx()
| Method Detail |
|---|
public java.lang.Object get(java.lang.String name,
int index)
It is extended from the Struts default so that the null is returned when the index is out of scope.
get in interface org.apache.commons.beanutils.DynaBeanget in class org.apache.struts.action.DynaActionFormname - Field nameindex - Index
public java.lang.Object getIndexedValue(java.lang.String name,
int index)
It is extended from the Struts default so that the null is returned when the index is out of scope.
getIndexedValue in interface FormExname - Field nameindex - Index
public int getIndexCount(java.lang.String fieldName)
getIndexCount in interface FormExfieldName - Name of the field for fetching the records.
Returns 0 when it is not possible to fetch the property name.
public void reset(org.apache.struts.action.ActionMapping mapping,
javax.servlet.http.HttpServletRequest request)
reset in class org.apache.struts.validator.DynaValidatorFormmapping - Mapping informationrequest - Request information
public void setIndexedValue(java.lang.String name,
int index,
java.lang.Object value)
In DynaActionForm of Struts, when the property type is changed to List type or array type, type need to be initialized and size need to be decided before use. However, this class is extended in such a way that this process can be skipped by dynamically changing the size.
setIndexedValue in interface FormExname - Field name to be setindex - Index to be setvalue - Field value to be set
public void set(java.lang.String name,
int index,
java.lang.Object value)
In DynaActionForm of Struts, when the property type is changed to List type or array type, type need to be initialized and size need to be decided before use. However, this class is extended in such a way that this process can be skipped by dynamically changing the size.
set in interface org.apache.commons.beanutils.DynaBeanset in class org.apache.struts.action.DynaActionFormname - Field name to be setindex - Index to be setvalue - Field value to be setpublic boolean isModified()
isModified in interface FormExpublic void setModified(boolean modified)
setModified in interface FormExmodified - Field value change flag
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||