de.cau.cs.kieler.core.model.xtext.triggers
Class XtextBasedEditorActivationChangeTrigger.XtextModelChangeState

java.lang.Object
  extended by de.cau.cs.kieler.core.kivi.AbstractTriggerState
      extended by de.cau.cs.kieler.core.model.xtext.triggers.XtextBasedEditorActivationChangeTrigger.XtextModelChangeState
All Implemented Interfaces:
ITriggerState
Enclosing class:
XtextBasedEditorActivationChangeTrigger

public static class XtextBasedEditorActivationChangeTrigger.XtextModelChangeState
extends AbstractTriggerState
implements ITriggerState

An ITriggerState indicating opening, modifying, or closing events of Xtext-based editors.

Rating red

Nested Class Summary
static class XtextBasedEditorActivationChangeTrigger.XtextModelChangeState.EventType
          Type of event to be denoted.
 
Constructor Summary
XtextBasedEditorActivationChangeTrigger.XtextModelChangeState()
          Default constructor.
XtextBasedEditorActivationChangeTrigger.XtextModelChangeState(org.eclipse.xtext.ui.editor.XtextEditor theEditor, XtextBasedEditorActivationChangeTrigger.XtextModelChangeState.EventType theEventType)
          Convenience constructor.
XtextBasedEditorActivationChangeTrigger.XtextModelChangeState(org.eclipse.xtext.ui.editor.XtextEditor theEditor, XtextBasedEditorActivationChangeTrigger.XtextModelChangeState.EventType theEventType, org.eclipse.xtext.resource.XtextResource theResource)
          Complete constructor.
 
Method Summary
 org.eclipse.xtext.ui.editor.XtextEditor getEditor()
          Getter for the editor field.
 IPath getEditorInputPath()
          Reveals the path of the denoted editor's IEditorInput.
 XtextBasedEditorActivationChangeTrigger.XtextModelChangeState.EventType getEventType()
          Getter for the eventType field.
 org.eclipse.xtext.resource.XtextResource getResource()
          Getter for the resource field.
 Class<? extends ITrigger> getTriggerClass()
          Get the trigger class associated with this trigger state.
 ITriggerState setEditor(org.eclipse.xtext.ui.editor.XtextEditor theEditor)
          Setter for the editor field.
 ITriggerState setEventType(XtextBasedEditorActivationChangeTrigger.XtextModelChangeState.EventType theEventType)
          Setter for the eventType field.
 ITriggerState setResource(org.eclipse.xtext.resource.XtextResource theResource)
          Setter for the resource field.
 
Methods inherited from class de.cau.cs.kieler.core.kivi.AbstractTriggerState
finish, getKeyClass, getSequenceNumber, merge, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface de.cau.cs.kieler.core.kivi.ITriggerState
finish, getKeyClass, getSequenceNumber, merge
 

Constructor Detail

XtextBasedEditorActivationChangeTrigger.XtextModelChangeState

public XtextBasedEditorActivationChangeTrigger.XtextModelChangeState()
Default constructor.


XtextBasedEditorActivationChangeTrigger.XtextModelChangeState

public XtextBasedEditorActivationChangeTrigger.XtextModelChangeState(org.eclipse.xtext.ui.editor.XtextEditor theEditor,
                                                                     XtextBasedEditorActivationChangeTrigger.XtextModelChangeState.EventType theEventType)
Convenience constructor.

Parameters:
theEditor - the editor the event has taken place of.
theEventType - the event type description.

XtextBasedEditorActivationChangeTrigger.XtextModelChangeState

public XtextBasedEditorActivationChangeTrigger.XtextModelChangeState(org.eclipse.xtext.ui.editor.XtextEditor theEditor,
                                                                     XtextBasedEditorActivationChangeTrigger.XtextModelChangeState.EventType theEventType,
                                                                     org.eclipse.xtext.resource.XtextResource theResource)
Complete constructor.

Parameters:
theEditor - the editor the event has taken place of.
theEventType - the event type description.
theResource - resource that is maintained by the editor. This parameter can be supplied in addition to the editor in order to avoid the costly grabbing via the transaction mechanism.
Method Detail

getTriggerClass

public Class<? extends ITrigger> getTriggerClass()
Get the trigger class associated with this trigger state.

Specified by:
getTriggerClass in interface ITriggerState
Returns:
the trigger class

getEditor

public org.eclipse.xtext.ui.editor.XtextEditor getEditor()
Getter for the editor field.

Returns:
the value of the editor field.

getEditorInputPath

public IPath getEditorInputPath()
Reveals the path of the denoted editor's IEditorInput. That IEditorInput is assumed to be a FileEditorInput.

Returns:
the IPath of the denoted editor's IEditorInput.

getEventType

public XtextBasedEditorActivationChangeTrigger.XtextModelChangeState.EventType getEventType()
Getter for the eventType field.

Returns:
the value of the eventType field.

getResource

public org.eclipse.xtext.resource.XtextResource getResource()
Getter for the resource field.

Returns:
the value of the resource field.

setEditor

public ITriggerState setEditor(org.eclipse.xtext.ui.editor.XtextEditor theEditor)
Setter for the editor field.

Parameters:
theEditor - the new value for the editor field.
Returns:
the currently manipulated ITriggerState object.

setEventType

public ITriggerState setEventType(XtextBasedEditorActivationChangeTrigger.XtextModelChangeState.EventType theEventType)
Setter for the eventType field.

Parameters:
theEventType - the new value for the eventType field.
Returns:
the currently manipulated ITriggerState object.

setResource

public ITriggerState setResource(org.eclipse.xtext.resource.XtextResource theResource)
Setter for the resource field.

Parameters:
theResource - the new value for the resource field.
Returns:
the currently manipulated ITriggerState object.