1717
1818import static com .mgs .fantasi .properties .UIPropertyFactory .uiProperty ;
1919import static com .mgs .fantasi .structure .BluePrintPatternFactory .newBluePrintBuilder ;
20- import static com .mgs .fantasi .wireframe .Wireframes .newRectangularAllUIPropertiesEmptyWireframe ;
20+ import static com .mgs .fantasi .wireframe .Wireframes .rectangularWireframe ;
2121
2222public class Main {
2323 public static void main (String ... args ) {
@@ -33,26 +33,27 @@ private void go(UIProfile uiProfile) {
3333 UIProperty <Measurement > hexagonMeasurement = uiProperty (Measurements .futureMeasurement (), UIPropertyType .MEASUREMENT );
3434
3535 BluePrint bluePrint =
36- newBluePrintBuilder ("main_frame" , new LayeredPattern ()).
37- withWireframe (newRectangularAllUIPropertiesEmptyWireframe ()).
38- withLayer (
39- newBluePrintBuilder ("odd_hexagons" , new HexagonRowsPattern ()).
40- withWireframe (newRectangularAllUIPropertiesEmptyWireframe ()).
41- withNumberOfGenerations (numberOfGenerations ).
42- withNumberOfVerticalDivisions (numberOVerticalDivisions ).
43- withHexagonSize (hexagonMeasurement )
44- ).
45- withLayer (
46- newBluePrintBuilder ("even_hexagons" , new HexagonRowsPattern ()).
47- withWireframe (newRectangularAllUIPropertiesEmptyWireframe ()).
48- withNumberOfGenerations (numberOfGenerations ).
49- withNumberOfVerticalDivisions (numberOVerticalDivisions ).
50- withHexagonSize (hexagonMeasurement )
51- ).
52- buildBlueprint ();
36+ newBluePrintBuilder ("main_frame" ).
37+ withWireframe (rectangularWireframe ()).
38+ withContent (
39+ new LayeredPattern ().
40+ withLayer (
41+ newBluePrintBuilder ("odd_hexagons" , new HexagonRowsPattern ()).
42+ withWireframe (rectangularWireframe ()).
43+ withNumberOfGenerations (numberOfGenerations ).
44+ withNumberOfVerticalDivisions (numberOVerticalDivisions ).
45+ withHexagonSize (hexagonMeasurement )
46+ ).
47+ withLayer (
48+ newBluePrintBuilder ("even_hexagons" , new HexagonRowsPattern ()).
49+ withWireframe (rectangularWireframe ()).
50+ withNumberOfGenerations (numberOfGenerations ).
51+ withNumberOfVerticalDivisions (numberOVerticalDivisions ).
52+ withHexagonSize (hexagonMeasurement )
53+ )
54+ ).buildBlueprint ();
5355 Structure tree = bluePrint .buildStructure ();
5456
5557 uiDriver .show (tree , new Dimension (400 , 400 ), uiProfile );
5658 }
57-
5859}
0 commit comments