Package org.opt4j.viewer


package org.opt4j.viewer

Provides the classes for the optimization visualization, i.e., the Viewer.

The Viewer is a JFrame consisting of the following elements:

  • ToolBar - a panel for arbitrary buttons
  • Viewport - a desktop for the widgets

The Viewport is a desktop for Widget elements. A widget is similar to a JInternalFrame, several properties are defined in the WidgetParameters. Widgets are added directly to the viewport.

Additional buttons are added to the ToolBar using the ToolBarService. Each ToolBarService is added in the VisualizationModule.

One predefined specific widget is the ArchiveWidget. This widget shows all Individuals which are currently in the Archive. By default, these are the best Individuals found so far during the optimization process. In practice a user might want to visualize one of these Individuals or their Phenotype, respectively. The IndividualMouseListener is used to listen to the double-clicking of an Individual in the Archive as well as a popup handling which is usually invoked by a right-click. An IndividualMouseListener is added in the VisualizationModule.