|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.empire.struts2.actionsupport.FormActionSupport
org.apache.empire.struts2.actionsupport.RecordFormActionSupport
org.apache.empire.struts2.actionsupport.BeanActionSupport<T>
public class BeanActionSupport<T>
BeanActionSupport
This class provides functions for form data processing through ordinary JavaBean or Data Transfer Objects (DTO).
Metadata for the Beans should be provided using the BeanClass and BeanProperty classes.
It is recommended (but not necessary) to create a subclass of the BeanRecordProxy<T> class in order to provide
further context specific metadata.
Field Summary |
---|
Fields inherited from class org.apache.empire.struts2.actionsupport.RecordFormActionSupport |
---|
persistence |
Fields inherited from class org.apache.empire.struts2.actionsupport.FormActionSupport |
---|
action, log, propertyName |
Constructor Summary | |
---|---|
BeanActionSupport(ActionBase action,
BeanClass beanClass,
SessionPersistence persistence)
|
|
BeanActionSupport(ActionBase action,
BeanClass beanClass,
SessionPersistence persistence,
String propertyName)
|
|
BeanActionSupport(ActionBase action,
BeanRecordProxy<T> record,
SessionPersistence persistence)
|
|
BeanActionSupport(ActionBase action,
BeanRecordProxy<T> record,
SessionPersistence persistence,
String propertyName)
|
|
BeanActionSupport(ActionBase action,
List<Column> updateColumns,
Column[] keyColumns,
SessionPersistence persistence)
|
|
BeanActionSupport(ActionBase action,
List<Column> updateColumns,
Column[] keyColumns,
SessionPersistence persistence,
String propertyName)
|
|
BeanActionSupport(ActionBase action,
List<Column> updateColumns,
Column keyColumn,
SessionPersistence persistence)
|
Method Summary | |
---|---|
boolean |
checkKey()
Checks wether the key supplied with the request is identical to the key of the current record. |
T |
getData()
Gets the bean data. |
Record |
getRecord()
returns the Record interface implementation for the bean |
Object[] |
getRecordKeyValues()
Returns the current key values of the bean attached to the record proxy. |
void |
initKeyColumns()
Initializes the key columns of the current record from the action parameters. |
boolean |
isValid()
Checks wether or not the record has a bean object attached |
void |
setData(T data)
Sets the bean data. |
void |
updateSessionKey()
Refreshes the record key stored on the session. |
Methods inherited from class org.apache.empire.struts2.actionsupport.RecordFormActionSupport |
---|
compareKey, getActionParamKey, getActionParamNewFlag, getPersistence, getRecordFromSession, getRecordKeyString, getRequestFieldName, hasActionKey, isNewRecord, loadFormData, persistOnSession, removeFromSession, setRecordFieldValue, setUpdateFields |
Methods inherited from class org.apache.empire.struts2.actionsupport.FormActionSupport |
---|
addFieldError, getActionParam, getRecordPropertyName, isEnableFieldErrors, setEnableFieldErrors |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BeanActionSupport(ActionBase action, BeanRecordProxy<T> record, SessionPersistence persistence, String propertyName)
public BeanActionSupport(ActionBase action, BeanRecordProxy<T> record, SessionPersistence persistence)
public BeanActionSupport(ActionBase action, BeanClass beanClass, SessionPersistence persistence, String propertyName)
public BeanActionSupport(ActionBase action, BeanClass beanClass, SessionPersistence persistence)
public BeanActionSupport(ActionBase action, List<Column> updateColumns, Column[] keyColumns, SessionPersistence persistence, String propertyName)
public BeanActionSupport(ActionBase action, List<Column> updateColumns, Column[] keyColumns, SessionPersistence persistence)
public BeanActionSupport(ActionBase action, List<Column> updateColumns, Column keyColumn, SessionPersistence persistence)
Method Detail |
---|
public Record getRecord()
getRecord
in class RecordFormActionSupport
public boolean isValid()
public T getData()
public void setData(T data)
data
- the bean data objectpublic Object[] getRecordKeyValues()
public boolean checkKey()
public void updateSessionKey()
public void initKeyColumns()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |