Package org.openxava.actions
Class OnSelectElementBaseAction
java.lang.Object
org.openxava.actions.BaseAction
org.openxava.actions.ViewBaseAction
org.openxava.actions.CollectionElementViewBaseAction
org.openxava.actions.CollectionBaseAction
org.openxava.actions.OnSelectElementBaseAction
- All Implemented Interfaces:
IAction,IChangeModeAction,IModuleContextAction,IRequestAction
Base action for actions executed when a collection element is selected or unselected.
This type of action is defined using {link org.openxava.annotations.OnSelectElementAction}
annotation, or its XML counterpart on-select-element-action.
This is a convenience class, if you want you can extend directly from
{link CollectionBaseAction} and add the properties row and selected
to your own action.
- Author:
- Javier Paniza
-
Field Summary
Fields inherited from interface org.openxava.actions.IChangeModeAction
DETAIL, LIST, PREVIOUS_MODE, SPLIT -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract voidexecute()intgetRow()Row number of the selected or unselected element.booleanIf the element has been selected or unselected.protected booleanvoidsetRow(int row) voidsetSelected(boolean selected) Methods inherited from class org.openxava.actions.CollectionBaseAction
getMapsSelectedValues, getMapValues, getObjects, getSelectedKeys, getSelectedObjectsMethods inherited from class org.openxava.actions.CollectionElementViewBaseAction
closeDialog, getCollectionElementView, getCollectionLabel, getMetaCollection, getMetaCollectionView, getParentView, getView, getViewObject, isCloseDialogDisallowed, isEntityReferencesCollection, isEntityReferencesCollection, setCloseDialogDisallowed, setViewObject, showDialog, validateMaximum, validateMinimumMethods inherited from class org.openxava.actions.ViewBaseAction
changeThisPropertyByViewValue, getModelName, getPreviousView, getPreviousViews, resetDescriptionsCache, returnToPreviousView, setControllers, setPreviousViews, setView, showDialog, showNewView, showView, validateViewValuesMethods inherited from class org.openxava.actions.BaseAction
addActions, addError, addErrors, addInfo, addMessage, addMessages, addWarning, clearActions, commit, executeAction, executeAfter, executeBefore, getContext, getEnvironment, getErrors, getLocale, getManager, getMessages, getNextMode, getQualifiedActionIfAvailable, getRequest, removeActions, returnToPreviousControllers, rollback, setContext, setDefaultControllers, setEnvironment, setErrors, setMessages, setNextMode, setRequest
-
Constructor Details
-
OnSelectElementBaseAction
public OnSelectElementBaseAction()
-
-
Method Details
-
execute
- Specified by:
executein interfaceIAction- Specified by:
executein classCollectionElementViewBaseAction- Throws:
Exception
-
mustRefreshCollection
protected boolean mustRefreshCollection()- Overrides:
mustRefreshCollectionin classCollectionElementViewBaseAction
-
getRow
public int getRow()Row number of the selected or unselected element.- Overrides:
getRowin classCollectionBaseAction
-
setRow
public void setRow(int row) - Overrides:
setRowin classCollectionBaseAction
-
isSelected
public boolean isSelected()If the element has been selected or unselected. -
setSelected
public void setSelected(boolean selected)
-