Class MeasurementsTreeViewer
- java.lang.Object
-
- org.palladiosimulator.measurementsui.abstractviewer.ComponentViewer
-
- org.palladiosimulator.measurementsui.abstractviewer.SaveableComponentViewer
-
- org.palladiosimulator.measurementsui.abstractviewer.MeasurementsTreeViewer
-
- Direct Known Subclasses:
EmptyMeasuringPointsTreeViewer,MonitorTreeViewer,SloTreeViewer
public abstract class MeasurementsTreeViewer extends SaveableComponentViewer
Creates a eclipse.swt TreeView based on a parsley TreeView project.
-
-
Field Summary
Fields Modifier and Type Field Description protected org.eclipse.emf.parsley.viewers.ViewerFactorytreeFactoryprotected TreeViewertreeViewer-
Fields inherited from class org.palladiosimulator.measurementsui.abstractviewer.SaveableComponentViewer
commandService, dirty
-
Fields inherited from class org.palladiosimulator.measurementsui.abstractviewer.ComponentViewer
editingDomain, injector, modelRepository, resource
-
-
Constructor Summary
Constructors Constructor Description MeasurementsTreeViewer(Composite parent, MDirtyable dirty, org.eclipse.e4.core.commands.ECommandService commandService, EObject modelRepository)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddMouseListener()Adds a DoubleClickMouseListener which changes Attributes if an icon in the treeview is double clicked.voidaddSelectionListener(ESelectionService selectionService)Adds a listener which connects the selected tree item to the ESelectionService.StructuredViewergetViewer()Return the TreeViewerprotected voidinitParsley(Composite parent)Initialize the connection between the e4 plugin and the Parsley TreeViewvoidupdate()Updates the underlying resources of the tree and redraws the componentvoidupdate(EObject modelRepository)-
Methods inherited from class org.palladiosimulator.measurementsui.abstractviewer.SaveableComponentViewer
redo, save, save, undo, undoAll, updateResource
-
Methods inherited from class org.palladiosimulator.measurementsui.abstractviewer.ComponentViewer
getModelRepository, initContextMenu, initDragAndDrop, initEditingDomain, initInjector, setModelRepository
-
-
-
-
Field Detail
-
treeViewer
protected TreeViewer treeViewer
-
treeFactory
protected org.eclipse.emf.parsley.viewers.ViewerFactory treeFactory
-
-
Constructor Detail
-
MeasurementsTreeViewer
public MeasurementsTreeViewer(Composite parent, MDirtyable dirty, org.eclipse.e4.core.commands.ECommandService commandService, EObject modelRepository)
- Parameters:
parent- a container where the view is embeddeddirty- the dirty state which indicates whether there were changes made in the viewercommandService- a service of the eclipse application in order to make the tree view saveablemodelRepository- EObject which is shown in the view
-
-
Method Detail
-
addMouseListener
public void addMouseListener()
Adds a DoubleClickMouseListener which changes Attributes if an icon in the treeview is double clicked.
-
getViewer
public StructuredViewer getViewer()
Return the TreeViewer- Specified by:
getViewerin classComponentViewer- Returns:
- the current TreeViewer
-
addSelectionListener
public void addSelectionListener(ESelectionService selectionService)
Adds a listener which connects the selected tree item to the ESelectionService.- Specified by:
addSelectionListenerin classSaveableComponentViewer- Parameters:
selectionService- the Eclipse SelectionService to which the selected element is passed on
-
initParsley
protected void initParsley(Composite parent)
Description copied from class:ComponentViewerInitialize the connection between the e4 plugin and the Parsley TreeView- Specified by:
initParsleyin classComponentViewer- Parameters:
parent- composite container
-
update
public void update(EObject modelRepository)
- Specified by:
updatein classSaveableComponentViewer
-
update
public void update()
Description copied from class:ComponentViewerUpdates the underlying resources of the tree and redraws the component- Specified by:
updatein classComponentViewer
-
-