g-Eclipse
Release 1.0.0

eu.geclipse.jsdl.ui.editors
Class JsdlEditor

java.lang.Object
  extended by FormEditor
      extended by eu.geclipse.jsdl.ui.editors.JsdlEditor

public final class JsdlEditor
extends FormEditor

This class provides a Multi-Page Editor for editing JSDL Documents. It comprises of four pages and a raw source editor.

See Also:

,

,

,


Constructor Summary
JsdlEditor()
          JsdlEditor Class Constructor.
 
Method Summary
 Diagnostic analyzeResourceProblems(Resource resource, java.lang.Exception exception)
          This looks up a string in plug-in.properties, making a substitution.
 void dispose()
           
 void doSave(IProgressMonitor monitor)
           
 void doSaveAs()
           
 EditingDomain getEditingDomain()
           
 IManagedForm getHeaderForm()
          Returns the header form of the JSDL editors Active Page
 boolean getJsdlModel()
          Responsible for de-serializing the model from the resource file.
 Form getTopForm()
           
 void init(IEditorSite site, IEditorInput editorInput)
           
 boolean isModelRefreshed()
           
 boolean isSaveAsAllowed()
           
 void setDirty(boolean dirtyFlag)
          This method set's the dirty status of the editor.
 void setMessage(java.lang.String message, int type)
          Used to define the message that will appear in the header of a page.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JsdlEditor

public JsdlEditor()
JsdlEditor Class Constructor.

Method Detail

setDirty

public void setDirty(boolean dirtyFlag)
This method set's the dirty status of the editor.

Parameters:
dirtyFlag - If TRUE then the page is Dirty and a Save operation is needed.

dispose

public void dispose()

getHeaderForm

public IManagedForm getHeaderForm()
Returns the header form of the JSDL editors Active Page

Returns:
the header of the active page.

setMessage

public void setMessage(java.lang.String message,
                       int type)
Used to define the message that will appear in the header of a page. This can be a message concerning a warning or an error that needs to be displayed to the user.

Parameters:
message - The message that needs to be displayed.
type - The type of the message. Possible message types are:
IMessageProvider.WARNING,
IMessageProvider.ERROR,
IMessageProvider.INFORMATION

getTopForm

public Form getTopForm()
Returns:
the top Form

isModelRefreshed

public boolean isModelRefreshed()
Returns:
true if the the JSDL Model was refreshed / changed. This could be caused by an external editor.

init

public void init(IEditorSite site,
                 IEditorInput editorInput)

doSave

public void doSave(IProgressMonitor monitor)

doSaveAs

public void doSaveAs()

isSaveAsAllowed

public boolean isSaveAsAllowed()

getJsdlModel

public boolean getJsdlModel()
Responsible for de-serializing the model from the resource file. The resource is passed to the getResourceRoot method.

Returns:
Returns TRUE if the Model was loaded.

analyzeResourceProblems

public Diagnostic analyzeResourceProblems(Resource resource,
                                          java.lang.Exception exception)
This looks up a string in plug-in.properties, making a substitution. Returns a diagnostic describing the errors and warnings listed in the resource and the specified exception.

Parameters:
resource - The Resource.
exception - The Exception.
Returns:
Diagnostic The Diagnostic.

getEditingDomain

public EditingDomain getEditingDomain()

g-Eclipse
Release 1.0.0