Search in sources :

Example 1 with VacuumEnvironmentViewCtrl

use of aima.gui.fx.views.VacuumEnvironmentViewCtrl in project aima-java by aimacode.

the class VacuumAgentApp method createRootPane.

/**
     * Defines state view, parameters, and call-back functions and calls the
     * simulation pane builder to create layout and controller objects.
     */
@Override
public Pane createRootPane() {
    BorderPane root = new BorderPane();
    StackPane envView = new StackPane();
    envViewCtrl = new VacuumEnvironmentViewCtrl(envView);
    List<Parameter> params = createParameters();
    SimulationPaneBuilder builder = new SimulationPaneBuilder();
    builder.defineParameters(params);
    builder.defineStateView(envView);
    builder.defineInitMethod(this::initialize);
    builder.defineSimMethod(this::simulate);
    simPaneCtrl = builder.getResultFor(root);
    return root;
}
Also used : VacuumEnvironmentViewCtrl(aima.gui.fx.views.VacuumEnvironmentViewCtrl) BorderPane(javafx.scene.layout.BorderPane) SimulationPaneBuilder(aima.gui.fx.framework.SimulationPaneBuilder) Parameter(aima.gui.fx.framework.Parameter) StackPane(javafx.scene.layout.StackPane)

Aggregations

Parameter (aima.gui.fx.framework.Parameter)1 SimulationPaneBuilder (aima.gui.fx.framework.SimulationPaneBuilder)1 VacuumEnvironmentViewCtrl (aima.gui.fx.views.VacuumEnvironmentViewCtrl)1 BorderPane (javafx.scene.layout.BorderPane)1 StackPane (javafx.scene.layout.StackPane)1