Class Controller
- java.lang.Object
-
- edu.kit.ipd.sdq.eventsim.rvisualization.Controller
-
public class Controller extends Object
Glues together theFilterView
andDiagramView
on the one side, and theFilterModel
andFilterSelectionModel
on the other side.Responsibilities of this controller include:
- observe
FilterSelectionModel
for selection events (mainly triggered by the user), and react to the selection by modifying theFilterModel
. Data binding established by theFilterView
ensures that the view reflects the model at any time. Explicit view updates triggered by this controller are not required, usually. Likewise, it is not necessary to query the view's (selection) state because the (selection) model provides that information. - populate the
FilterModel
from measurements stored in R with the help of theRController
. - trigger diagram plots in R with the help of the
RController
.
- observe
-
-
Constructor Summary
Constructors Constructor Description Controller(FilterView view, FilterSelectionModel selectionModel, FilterModel model)
Create an application controller.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clearSelectionTriggerInstances()
void
clearSelectionTriggerTypes()
void
loadRDS(String path)
void
metadataSelectionChanged(TranslatableEntity metadataType, Metadata metadataLevel)
void
metadataSelectionCleared()
void
plotDiagram()
Plots the diagram according to the currentFilterSelectionModel
.void
reload()
void
resetSimulationTimeBounds()
void
viewInitialized()
-
-
-
Constructor Detail
-
Controller
public Controller(FilterView view, FilterSelectionModel selectionModel, FilterModel model)
Create an application controller. The application controller creates a RController to manage the R connection and a MeasurementView to open the main SWT dialog.
-
-
Method Detail
-
viewInitialized
public final void viewInitialized()
-
reload
public final void reload()
-
loadRDS
public void loadRDS(String path)
- Parameters:
path
- the path to the RDS file to be loaded. All occurrences of "\" will be converted to "/" for compliance with R.
-
resetSimulationTimeBounds
public final void resetSimulationTimeBounds()
-
clearSelectionTriggerTypes
public void clearSelectionTriggerTypes()
-
clearSelectionTriggerInstances
public void clearSelectionTriggerInstances()
-
plotDiagram
public final void plotDiagram()
Plots the diagram according to the currentFilterSelectionModel
. The generated diagram will be opened in a newDiagramView
.
-
metadataSelectionChanged
public void metadataSelectionChanged(TranslatableEntity metadataType, Metadata metadataLevel)
-
metadataSelectionCleared
public void metadataSelectionCleared()
-
-