Package org.opt4j.viewer
Class Viewer
- java.lang.Object
-
- org.opt4j.viewer.Viewer
-
- All Implemented Interfaces:
OptimizerStateListener
public class Viewer extends Object implements OptimizerStateListener
TheViewer
.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Viewer.CloseEvent
TheViewer.CloseEvent
that is triggered if this viewer is closed.
-
Field Summary
Fields Modifier and Type Field Description protected Viewer.CloseEvent
closeEvent
protected boolean
closeOnStop
protected Control
control
protected JFrame
frame
protected StatusBar
statusBar
protected String
title
protected ToolBar
toolBar
protected Viewport
viewport
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
optimizationStarted(Optimizer optimizer)
Invoked if theOptimizer
starts the optimization process.void
optimizationStopped(Optimizer optimizer)
Invoked if theOptimizer
stops the optimization process.
-
-
-
Field Detail
-
control
protected final Control control
-
closeEvent
protected final Viewer.CloseEvent closeEvent
-
closeOnStop
protected final boolean closeOnStop
-
title
protected final String title
-
viewport
protected final Viewport viewport
-
toolBar
protected final ToolBar toolBar
-
statusBar
protected final StatusBar statusBar
-
frame
protected JFrame frame
-
-
Constructor Detail
-
Viewer
@Inject public Viewer(Viewport viewport, ToolBar toolBar, StatusBar statusBar, Control control, String title, Viewer.CloseEvent closeEvent, boolean closeOnStop)
Constructs aViewer
.- Parameters:
viewport
- the viewporttoolBar
- the toolBarstatusBar
- the statusBarcontrol
- the controltitle
- the title of the framecloseEvent
- event on closing the GUI windowcloseOnStop
- close window at the end of the optimization run
-
-
Method Detail
-
optimizationStarted
public void optimizationStarted(Optimizer optimizer)
Description copied from interface:OptimizerStateListener
Invoked if theOptimizer
starts the optimization process.- Specified by:
optimizationStarted
in interfaceOptimizerStateListener
- Parameters:
optimizer
- the optimizer
-
optimizationStopped
public void optimizationStopped(Optimizer optimizer)
Description copied from interface:OptimizerStateListener
Invoked if theOptimizer
stops the optimization process.- Specified by:
optimizationStopped
in interfaceOptimizerStateListener
- Parameters:
optimizer
- the optimizer
-
-