org.talend.commons.ui.swt.actions
Interface ITreeContextualAction

All Superinterfaces:
org.eclipse.jface.action.IAction
All Known Implementing Classes:
AbstractCreateAction, AbstractCreateTableAction, AbstractRoutineAction, AContextualAction, ConfigRoutineLibraryAction, CopyAction, CreateConnectionAction, CreateContextAction, CreateDiagramAction, CreateDocumentationAction, CreateFileDelimitedAction, CreateFileLdifAction, CreateFilePositionalAction, CreateFileRegexpAction, CreateFileXmlAction, CreateFolderAction, CreateProcess, CreateRoutineAction, CreateTableAction, DeleteAction, DeleteTableAction, EditContextAction, EditProcess, EditPropertiesAction, EditQueriesAction, EditRoutineAction, EmptyRecycleBinAction, ExpandAllAction, ExportJobScriptAction, ExtractDocumentationAction, FindAssignmentAction, GenerateDocAsHTMLAction, ImportItemAction, OpenDiagramAction, OpenDocumentationAction, PasteAction, ReadContextAction, ReadDiagramAction, ReadProcess, ReadQueriesAction, ReadRoutineAction, ReadTableAction, RenameFolderAction, RestoreAction, UpdateDocumentationAction

public interface ITreeContextualAction
extends org.eclipse.jface.action.IAction

Defines contextual actions used on a TreeViewer. $Id: ITreeContextualAction.java 2738 2007-03-28 13:12:27 +0000 (mer., 28 mars 2007) plegall $


Field Summary
 
Fields inherited from interface org.eclipse.jface.action.IAction
AS_CHECK_BOX, AS_DROP_DOWN_MENU, AS_PUSH_BUTTON, AS_RADIO_BUTTON, AS_UNSPECIFIED, CHECKED, DESCRIPTION, ENABLED, HANDLED, IMAGE, RESULT, TEXT, TOOL_TIP_TEXT
 
Method Summary
 java.lang.Class getClassForDoubleClick()
          Defines the Class on wich this action is launch by double-click.
 int getLevel()
           
 void init(org.eclipse.jface.viewers.TreeViewer viewer, org.eclipse.jface.viewers.IStructuredSelection selection)
          Initialise the action on a given tree with the actual selection.
 boolean isDoubleClickAction()
          Specifies if this action can be launch by double-click.
 boolean isEditAction()
           
 boolean isReadAction()
           
 boolean isVisible()
           
 void setEditAction(boolean editAction)
           
 void setLevel(int level)
           
 void setReadAction(boolean readAction)
           
 
Methods inherited from interface org.eclipse.jface.action.IAction
addPropertyChangeListener, getAccelerator, getActionDefinitionId, getDescription, getDisabledImageDescriptor, getHelpListener, getHoverImageDescriptor, getId, getImageDescriptor, getMenuCreator, getStyle, getText, getToolTipText, isChecked, isEnabled, isHandled, removePropertyChangeListener, run, runWithEvent, setAccelerator, setActionDefinitionId, setChecked, setDescription, setDisabledImageDescriptor, setEnabled, setHelpListener, setHoverImageDescriptor, setId, setImageDescriptor, setMenuCreator, setText, setToolTipText
 

Method Detail

init

void init(org.eclipse.jface.viewers.TreeViewer viewer,
          org.eclipse.jface.viewers.IStructuredSelection selection)
Initialise the action on a given tree with the actual selection.
Use the setEnabled method to anable/disable this action for the current selection.

Parameters:
viewer - - The tree.
selection - - Actual selection in the tree.

isDoubleClickAction

boolean isDoubleClickAction()
Specifies if this action can be launch by double-click.

Returns:
true if this action can be launch by double-click.

getClassForDoubleClick

java.lang.Class getClassForDoubleClick()
Defines the Class on wich this action is launch by double-click. Means that when a double-click occurs in the TreeViewer, the first registred IContextuelAction matching the selection Class is launch.

Returns:
the class correspondinf to this action

isVisible

boolean isVisible()

getLevel

int getLevel()

setLevel

void setLevel(int level)

isEditAction

boolean isEditAction()

setEditAction

void setEditAction(boolean editAction)

isReadAction

boolean isReadAction()

setReadAction

void setReadAction(boolean readAction)