modesteditor.core
Class ModestEditorPlugin

java.lang.Object
  extended by org.eclipse.core.runtime.Plugin
      extended by org.eclipse.ui.plugin.AbstractUIPlugin
          extended by modesteditor.core.ModestEditorPlugin
All Implemented Interfaces:
org.osgi.framework.BundleActivator

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

The activator class controls the plug-in life cycle of the complete Modesteditor plugin


Field Summary
static java.lang.String DIST
          Color attribute for the color in syntax highlighting.
static java.lang.String KEYWORD
          Color attribute for the color in syntax highlighting.
static java.lang.String MODEST_MARK_ERRORS
          Boolean attribute for whether to mark syntax errors in the editor.
static java.lang.String MODEST_PARTITIONING
           
static java.lang.String MULTI_LINE_COMMENT
          Color attribute for the color in syntax highlighting.
static java.lang.String PLUGIN_ID
           
static java.lang.String SINGLE_LINE_COMMENT
          Color attribute for the color in syntax highlighting.
static java.lang.String TYPE
          Color attribute for the color in syntax highlighting.
 
Fields inherited from class org.eclipse.core.runtime.Plugin
PLUGIN_PREFERENCE_SCOPE, PREFERENCES_DEFAULT_OVERRIDE_BASE_NAME, PREFERENCES_DEFAULT_OVERRIDE_FILE_NAME
 
Constructor Summary
ModestEditorPlugin()
          The constructor, initializes the plugin variable to fulfill the singleton pattern.
 
Method Summary
static ModestEditorPlugin getDefault()
          Returns the shared instance in order to make it a singleton
static org.eclipse.jface.resource.ImageDescriptor getImageDescriptor(java.lang.String name)
          Return the image descriptor of the given filename.
 org.eclipse.jface.text.rules.RuleBasedScanner getModestCodeScanner()
          Returns the singleton MoDeST code scanner.
 ModestColorProvider getModestColorProvider()
          Returns the singleton Modest color provider.
 ModestPartitionScanner getModestPartitionScanner()
          Return a scanner for creating MoDeST partitions.
 ModestTextStyleProvider getModestTextStyleProvider()
          Returns the singleton Modest text style provider.
protected  void initializeDefaultPluginPreferences()
          Initializes default values for this plug-in's preferences.
 void start(org.osgi.framework.BundleContext context)
          Start function which initializes the default preferences of the plugin
 void stop(org.osgi.framework.BundleContext context)
          Stop function which releases the context
 
Methods inherited from class org.eclipse.ui.plugin.AbstractUIPlugin
createImageRegistry, getDialogSettings, getImageRegistry, getPreferenceStore, getWorkbench, imageDescriptorFromPlugin, initializeDefaultPreferences, initializeImageRegistry, loadDialogSettings, loadPreferenceStore, refreshPluginActions, saveDialogSettings, savePreferenceStore, 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
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

PLUGIN_ID

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

MODEST_PARTITIONING

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

MULTI_LINE_COMMENT

public static final java.lang.String MULTI_LINE_COMMENT
Color attribute for the color in syntax highlighting.

See Also:
Constant Field Values

SINGLE_LINE_COMMENT

public static final java.lang.String SINGLE_LINE_COMMENT
Color attribute for the color in syntax highlighting.

See Also:
Constant Field Values

KEYWORD

public static final java.lang.String KEYWORD
Color attribute for the color in syntax highlighting.

See Also:
Constant Field Values

TYPE

public static final java.lang.String TYPE
Color attribute for the color in syntax highlighting.

See Also:
Constant Field Values

DIST

public static final java.lang.String DIST
Color attribute for the color in syntax highlighting.

See Also:
Constant Field Values

MODEST_MARK_ERRORS

public static final java.lang.String MODEST_MARK_ERRORS
Boolean attribute for whether to mark syntax errors in the editor.

See Also:
Constant Field Values
Constructor Detail

ModestEditorPlugin

public ModestEditorPlugin()
The constructor, initializes the plugin variable to fulfill the singleton pattern.

Method Detail

start

public void start(org.osgi.framework.BundleContext context)
           throws java.lang.Exception
Start function which initializes the default preferences of the plugin

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
Stop function which releases the context

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

getDefault

public static ModestEditorPlugin getDefault()
Returns the shared instance in order to make it a singleton

Returns:
the shared instance

getModestColorProvider

public ModestColorProvider getModestColorProvider()
Returns the singleton Modest color provider.

Returns:
the singleton Modest color provider

getModestTextStyleProvider

public ModestTextStyleProvider getModestTextStyleProvider()
Returns the singleton Modest text style provider.

Returns:
the singleton Modest text style provider

getModestCodeScanner

public org.eclipse.jface.text.rules.RuleBasedScanner getModestCodeScanner()
Returns the singleton MoDeST code scanner.

Returns:
the singleton MoDeST code scanner

getModestPartitionScanner

public ModestPartitionScanner getModestPartitionScanner()
Return a scanner for creating MoDeST partitions.

Returns:
a scanner for creating MoDeST partitions

getImageDescriptor

public static org.eclipse.jface.resource.ImageDescriptor getImageDescriptor(java.lang.String name)
Return the image descriptor of the given filename. The images have to be located in the icons folder.


initializeDefaultPluginPreferences

protected void initializeDefaultPluginPreferences()
Initializes default values for this plug-in's preferences.

Overrides:
initializeDefaultPluginPreferences in class org.eclipse.ui.plugin.AbstractUIPlugin