org.eclipse.gmt.umlx.editor
Class EditorPlugin

java.lang.Object
  extended by org.eclipse.core.runtime.Plugin
      extended by org.eclipse.ui.plugin.AbstractUIPlugin
          extended by org.eclipse.gmt.umlx.editor.EditorPlugin
All Implemented Interfaces:
org.osgi.framework.BundleActivator

public class EditorPlugin
extends org.eclipse.ui.plugin.AbstractUIPlugin

The main plugin class to be used in the desktop.


Field Summary
static java.lang.String EDITOR_SHEET_ID
           
static IEditorEnvironment environment
           
static java.lang.String PLUGIN_ID
           
static java.lang.String PROBLEM_MARKER_ID
           
static org.eclipse.core.runtime.QualifiedName SHARED_DOMAIN_PERSISTENT_PROPERTY
          The unique SharedEditDomain identity that enables the start upo of a Gcore editor to rejoin a shared session that may have exisyted in an earlier Eclipse invocation.
 
Fields inherited from class org.eclipse.core.runtime.Plugin
PLUGIN_PREFERENCE_SCOPE, PREFERENCES_DEFAULT_OVERRIDE_BASE_NAME, PREFERENCES_DEFAULT_OVERRIDE_FILE_NAME
 
Constructor Summary
EditorPlugin()
          The constructor.
 
Method Summary
static org.eclipse.emf.ecore.resource.Resource createGcoreResource(IActiveEditDomain editDomain, org.eclipse.emf.common.util.URI uri)
           
static IActiveEditDomain getActiveEditDomain()
           
static org.eclipse.ui.IEditorPart getActiveEditor()
           
static java.util.List<GImport> getActiveImports()
           
static org.eclipse.ui.IWorkbenchPage getActivePage()
           
static org.eclipse.ui.IWorkbenchPart getActivePart()
           
static IRegimeContext getActiveRegimeContext()
           
static org.eclipse.emf.ecore.resource.ResourceSet getActiveResourceSet()
           
static org.eclipse.jface.viewers.ISelectionProvider getActiveSelectionProvider()
           
static ISheetEditor getActiveSheetEditor()
           
static SheetViewer getActiveSheetViewer()
           
static org.eclipse.jface.action.IStatusLineManager getActiveStatusLineManager()
           
static EditorPlugin getDefault()
          Returns the shared instance.
static IEditorEnvironment getEnvironment()
          Returns the shared environment.
static org.eclipse.jface.resource.ImageDescriptor getImageDescriptor(java.lang.String path)
          Returns an image descriptor for the image file at the given plug-in relative path.
static void logException(java.lang.Throwable e, boolean showErrorDialog)
           
static boolean requestUnlock(org.eclipse.emf.ecore.resource.Resource resource)
           
 void start(org.osgi.framework.BundleContext context)
          This method is called upon plug-in activation
 void stop(org.osgi.framework.BundleContext context)
          This method is called when the plug-in is stopped
 
Methods inherited from class org.eclipse.ui.plugin.AbstractUIPlugin
getDialogSettings, getImageRegistry, getPreferenceStore, getWorkbench, imageDescriptorFromPlugin, shutdown, startup
 
Methods inherited from class org.eclipse.core.runtime.Plugin
find, find, getBundle, getDescriptor, getLog, getPluginPreferences, getStateLocation, internalInitializeDefaultPluginPreferences, isDebugging, openStream, openStream, savePluginPreferences, setDebugging, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

PLUGIN_ID

public static final java.lang.String PLUGIN_ID
See Also:
Constant Field Values

PROBLEM_MARKER_ID

public static final java.lang.String PROBLEM_MARKER_ID
See Also:
Constant Field Values

EDITOR_SHEET_ID

public static final java.lang.String EDITOR_SHEET_ID
See Also:
Constant Field Values

SHARED_DOMAIN_PERSISTENT_PROPERTY

public static final org.eclipse.core.runtime.QualifiedName SHARED_DOMAIN_PERSISTENT_PROPERTY
The unique SharedEditDomain identity that enables the start upo of a Gcore editor to rejoin a shared session that may have exisyted in an earlier Eclipse invocation.


environment

public static IEditorEnvironment environment
Constructor Detail

EditorPlugin

public EditorPlugin()
The constructor.

Method Detail

getActiveEditDomain

public static IActiveEditDomain getActiveEditDomain()

getActiveEditor

public static org.eclipse.ui.IEditorPart getActiveEditor()

getActiveImports

public static java.util.List<GImport> getActiveImports()

getActivePage

public static org.eclipse.ui.IWorkbenchPage getActivePage()

getActivePart

public static org.eclipse.ui.IWorkbenchPart getActivePart()

getActiveRegimeContext

public static IRegimeContext getActiveRegimeContext()

getActiveResourceSet

public static org.eclipse.emf.ecore.resource.ResourceSet getActiveResourceSet()

getActiveSelectionProvider

public static org.eclipse.jface.viewers.ISelectionProvider getActiveSelectionProvider()

getActiveSheetEditor

public static ISheetEditor getActiveSheetEditor()

getActiveSheetViewer

public static SheetViewer getActiveSheetViewer()

getActiveStatusLineManager

public static org.eclipse.jface.action.IStatusLineManager getActiveStatusLineManager()

getDefault

public static EditorPlugin getDefault()
Returns the shared instance.


getEnvironment

public static IEditorEnvironment getEnvironment()
Returns the shared environment.


createGcoreResource

public static org.eclipse.emf.ecore.resource.Resource createGcoreResource(IActiveEditDomain editDomain,
                                                                          org.eclipse.emf.common.util.URI uri)

logException

public static void logException(java.lang.Throwable e,
                                boolean showErrorDialog)

start

public void start(org.osgi.framework.BundleContext context)
           throws java.lang.Exception
This method is called upon plug-in activation

Specified by:
start in interface org.osgi.framework.BundleActivator
Overrides:
start in class org.eclipse.ui.plugin.AbstractUIPlugin
Throws:
java.lang.Exception

stop

public void stop(org.osgi.framework.BundleContext context)
          throws java.lang.Exception
This method is called when the plug-in is stopped

Specified by:
stop in interface org.osgi.framework.BundleActivator
Overrides:
stop in class org.eclipse.ui.plugin.AbstractUIPlugin
Throws:
java.lang.Exception

getImageDescriptor

public static org.eclipse.jface.resource.ImageDescriptor getImageDescriptor(java.lang.String path)
Returns an image descriptor for the image file at the given plug-in relative path.

Parameters:
path - the path
Returns:
the image descriptor

requestUnlock

public static boolean requestUnlock(org.eclipse.emf.ecore.resource.Resource resource)