org.eclipse.datatools.sqltools.sqleditor
Interface ISQLEditorActionContributorExtension

All Known Implementing Classes:
SQLEditorActionContributorExtension

public interface ISQLEditorActionContributorExtension

Author:
Hui Cao

Field Summary
static java.lang.String EDITOR_ID_ALL
           
 
Method Summary
 void contributeToContextMenu(org.eclipse.jface.action.IMenuManager mm)
          Contributes to the given SQLEditor context menu.
 void contributeToCoolBar(org.eclipse.jface.action.ICoolBarManager coolBarManager)
          Contributes to the given cool bar.
 void contributeToMenu(org.eclipse.jface.action.IMenuManager menuManager)
          Contributes to the given menu.
 void contributeToStatusLine(org.eclipse.jface.action.IStatusLineManager statusLineManager)
          Contributes to the given status line.
 void contributeToToolBar(org.eclipse.jface.action.IToolBarManager toolBarManager)
          Contributes to the given tool bar.
 void dispose()
          Disposes this contributor.
 void init(org.eclipse.ui.IActionBars bars, org.eclipse.ui.IWorkbenchPage page)
          Initializes this contributor, which is expected to add contributions as required to the given action bars and global action handlers.
 void menuAboutToShow(org.eclipse.jface.action.IMenuManager manager)
          Receives notification that the workbench menu is about to show.
 void setActiveEditor(SQLEditor targetEditor)
          Sets the active editor for the contributor.
 void setParent(org.eclipse.ui.editors.text.TextEditorActionContributor parent)
           
 void updateAction()
          Requests that this object update its actions.
 void updateAction(boolean isSQLEditorPage)
          Requests that this object update its actions when the page is switched.
 

Field Detail

EDITOR_ID_ALL

static final java.lang.String EDITOR_ID_ALL
See Also:
Constant Field Values
Method Detail

menuAboutToShow

void menuAboutToShow(org.eclipse.jface.action.IMenuManager manager)
Receives notification that the workbench menu is about to show.


contributeToContextMenu

void contributeToContextMenu(org.eclipse.jface.action.IMenuManager mm)
Contributes to the given SQLEditor context menu.

Parameters:
menuManager - the manager that controls the menu

init

void init(org.eclipse.ui.IActionBars bars,
          org.eclipse.ui.IWorkbenchPage page)
Initializes this contributor, which is expected to add contributions as required to the given action bars and global action handlers.

The page is passed to support the use of RetargetAction by the contributor. In this case the init method implementors should:

And in the dispose method the retarget actions should be removed as part listeners.

Parameters:
bars - the action bars
page - the workbench page for this contributor

setActiveEditor

void setActiveEditor(SQLEditor targetEditor)
Sets the active editor for the contributor. Implementors should disconnect from the old editor, connect to the new editor, and update the actions to reflect the new editor.

Parameters:
targetEditor - the new editor target

dispose

void dispose()
Disposes this contributor.


contributeToMenu

void contributeToMenu(org.eclipse.jface.action.IMenuManager menuManager)
Contributes to the given menu.

Parameters:
menuManager - the manager that controls the menu

contributeToStatusLine

void contributeToStatusLine(org.eclipse.jface.action.IStatusLineManager statusLineManager)
Contributes to the given status line.

Parameters:
statusLineManager - the manager of the status line

contributeToToolBar

void contributeToToolBar(org.eclipse.jface.action.IToolBarManager toolBarManager)
Contributes to the given tool bar.

Parameters:
toolBarManager - the manager that controls the workbench tool bar

contributeToCoolBar

void contributeToCoolBar(org.eclipse.jface.action.ICoolBarManager coolBarManager)
Contributes to the given cool bar.

Parameters:
coolBarManager - the manager that controls the workbench cool bar.

setParent

void setParent(org.eclipse.ui.editors.text.TextEditorActionContributor parent)

updateAction

void updateAction()
Requests that this object update its actions. This is equivalent to udpateAction(true).


updateAction

void updateAction(boolean isSQLEditorPage)
Requests that this object update its actions when the page is switched.

Parameters:
isSQLEditorPage - whether the active page is an embeded instance of SQLEditor.