Skip to content

Commit

Permalink
gs-example-reactor: Refactor: AppHtml3 -> AppHtml2, AppHtml5 -> AppHtml3
Browse files Browse the repository at this point in the history
  • Loading branch information
fducroquet committed Oct 13, 2016
1 parent 21b7b27 commit d132506
Show file tree
Hide file tree
Showing 3 changed files with 59 additions and 59 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
package org.genericsystem.reactor.example;

import org.genericsystem.reactor.modelproperties.SelectionDefaults;

import org.genericsystem.reactor.example.AppHtml.ExampleReactorScript;

import org.genericsystem.carcolor.model.Car;
import org.genericsystem.carcolor.model.CarColor;
import org.genericsystem.carcolor.model.CarColor2;
import org.genericsystem.carcolor.model.Color;
import org.genericsystem.carcolor.model.Power;
import org.genericsystem.carcolor.model.UsedCar;
import org.genericsystem.reactor.annotations.DependsOnModel;
import org.genericsystem.reactor.annotations.DirectSelect;
import org.genericsystem.reactor.annotations.ReactorDependencies;
import org.genericsystem.reactor.annotations.RunScript;
import org.genericsystem.reactor.annotations.Select.SelectModel;
import org.genericsystem.reactor.annotations.Style;
import org.genericsystem.reactor.appserver.ApplicationServer;
import org.genericsystem.reactor.gscomponents.GSApp;
import org.genericsystem.reactor.gscomponents2.GSEditor;
import org.genericsystem.reactor.gscomponents2.GSEditor.HorizontalGSEditor;
import org.genericsystem.reactor.gscomponents2.GSTable;
import org.genericsystem.reactor.gscomponents2.GSTable.HorizontalTable;
import org.genericsystem.reactor.model.ObservableModelSelector;

@DependsOnModel({ Car.class, Power.class, UsedCar.class, Color.class, CarColor.class, CarColor2.class })
@RunScript(ExampleReactorScript.class)
@ReactorDependencies({ GSTable.class, HorizontalTable.class, GSEditor.class, HorizontalGSEditor.class, GSTable.class })
@DirectSelect(path = GSTable.class, pos = 0, value = Car.class)
@DirectSelect(path = HorizontalTable.class, value = Car.class)
@SelectModel(path = GSEditor.class, value = ObservableModelSelector.SELECTION_SELECTOR.class)
@DirectSelect(path = GSTable.class, pos = 2, value = Color.class)
@Style(name = "justify-content", value = "center")
public class AppHtml2 extends GSApp implements SelectionDefaults {

public static void main(String[] mainArgs) {
ApplicationServer.startSimpleGenericApp(mainArgs, AppHtml2.class, "/example-reactor");
}

public AppHtml2() {
createSelectionProperty();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,25 @@
import org.genericsystem.reactor.annotations.Style;
import org.genericsystem.reactor.appserver.ApplicationServer;
import org.genericsystem.reactor.gscomponents.GSApp;
import org.genericsystem.reactor.gscomponents2.GSEditor;
import org.genericsystem.reactor.gscomponents2.GSEditor.HorizontalGSEditor;
import org.genericsystem.reactor.gscomponents2.GSTable;
import org.genericsystem.reactor.gscomponents2.GSTable.HorizontalTable;
import org.genericsystem.reactor.gscomponents3.DivWithTitle.TitledHorizontalInstanceEditor;
import org.genericsystem.reactor.gscomponents3.DivWithTitle.TitledHorizontalInstanceStepEditor;
import org.genericsystem.reactor.gscomponents3.DivWithTitle.TitledHorizontalInstancesTable;
import org.genericsystem.reactor.gscomponents3.DivWithTitle.TitledInstanceEditor;
import org.genericsystem.reactor.gscomponents3.DivWithTitle.TitledInstanceStepEditor;
import org.genericsystem.reactor.gscomponents3.DivWithTitle.TitledInstancesTable;
import org.genericsystem.reactor.gscomponents3.Monitor.MonitorExtended;
import org.genericsystem.reactor.model.ObservableModelSelector;

@DependsOnModel({ Car.class, Power.class, UsedCar.class, Color.class, CarColor.class, CarColor2.class })
@RunScript(ExampleReactorScript.class)
@ReactorDependencies({ GSTable.class, HorizontalTable.class, GSEditor.class, HorizontalGSEditor.class, GSTable.class })
@DirectSelect(path = GSTable.class, pos = 0, value = Car.class)
@DirectSelect(path = HorizontalTable.class, value = Car.class)
@SelectModel(path = GSEditor.class, value = ObservableModelSelector.SELECTION_SELECTOR.class)
@DirectSelect(path = GSTable.class, pos = 2, value = Color.class)
@Style(name = "justify-content", value = "center")
@ReactorDependencies({ TitledInstancesTable.class, TitledHorizontalInstancesTable.class, TitledInstancesTable.class, TitledInstanceEditor.class, TitledHorizontalInstanceEditor.class, TitledInstanceStepEditor.class, TitledHorizontalInstanceStepEditor.class,
MonitorExtended.class })
@DirectSelect(path = TitledInstancesTable.class, pos = 0, value = Car.class)
@DirectSelect(path = TitledHorizontalInstancesTable.class, pos = 0, value = Car.class)
@DirectSelect(path = TitledInstancesTable.class, pos = 2, value = Color.class)
@SelectModel(path = TitledInstanceEditor.class, value = ObservableModelSelector.SELECTION_SELECTOR.class)
@Style(name = "flex-wrap", value = "wrap")
@Style(name = "flex", value = "1 1 0%")
public class AppHtml3 extends GSApp implements SelectionDefaults {

public static void main(String[] mainArgs) {
Expand Down

This file was deleted.

0 comments on commit d132506

Please sign in to comment.