net.sourceforge.squirrel_sql.plugins.refactoring.actions
Class AbstractRefactoringAction
java.lang.Object
javax.swing.AbstractAction
net.sourceforge.squirrel_sql.fw.gui.action.BaseAction
net.sourceforge.squirrel_sql.client.action.SquirrelAction
net.sourceforge.squirrel_sql.plugins.refactoring.actions.AbstractRefactoringAction
- All Implemented Interfaces:
- ActionListener, Serializable, Cloneable, EventListener, Action, IObjectTreeAction
- Direct Known Subclasses:
- AddAutoIncrementAction, AddColumnAction, AddForeignKeyAction, AddIndexAction, AddLookupTableAction, AddPrimaryKeyAction, AddSequenceAction, AddUniqueConstraintAction, AddViewAction, DropColumnAction, DropForeignKeyAction, DropIndexTableAction, DropPrimaryKeyAction, DropSelectedTablesAction, DropSequenceAction, DropUniqueConstraintAction, DropViewAction, MergeColumnAction, MergeTableAction, ModifyColumnAction, ModifySequenceAction, RenameTableAction, RenameViewAction
public abstract class AbstractRefactoringAction
- extends SquirrelAction
- implements IObjectTreeAction
- See Also:
- Serialized Form
| Fields inherited from class net.sourceforge.squirrel_sql.client.action.SquirrelAction |
_app |
| Fields inherited from interface javax.swing.Action |
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON |
_session
protected ISession _session
- Current session.
_tree
protected IObjectTreeAPI _tree
- Current object tree.
AbstractRefactoringAction
public AbstractRefactoringAction(IApplication app,
Resources rsrc)
actionPerformed
public void actionPerformed(ActionEvent evt)
- Specified by:
actionPerformed in interface ActionListener
- See Also:
ActionListener.actionPerformed(java.awt.event.ActionEvent)
getCommand
protected abstract ICommand getCommand(IDatabaseObjectInfo[] info)
- Returns the command to be executed when this action is invoked.
- Parameters:
info - the selected object(s)
- Returns:
- the ICommand implementation to execute
isMultipleObjectAction
protected abstract boolean isMultipleObjectAction()
- Returns a boolean value indicating whether or not this action can be executed against multiple objects.
- Returns:
- true if the user can execute this action against multiple slected objects; false otherwise.
getErrorMessage
protected abstract String getErrorMessage()
- Subclasses must override this to provide a custom error message when the user chooses to execcute an
action on multiple selected objects, when the action can only be executed on a single object.
- Returns:
- the error message to use for single-object actions
setObjectTree
public void setObjectTree(IObjectTreeAPI tree)
- Specified by:
setObjectTree in interface IObjectTreeAction
- See Also:
IObjectTreeAction.setObjectTree(net.sourceforge.squirrel_sql.client.session.IObjectTreeAPI)
Copyright © 2001-2010. All Rights Reserved.