build method

WallBlueprint build({
  1. required int mainAxisSeparations,
  2. required bool reverse,
  3. required Axis direction,
  4. required List<Stone> stones,
})

Build the wall with scrollview parameters

Implementation

WallBlueprint build(
    {required int mainAxisSeparations,
    required bool reverse,
    required Axis direction,
    required List<Stone> stones}) {
  this._direction = direction;
  this._reverse = reverse;
  this._mainAxisSeparations = mainAxisSeparations;
  final positions = computeStonePositions(stones);
  assertNoOverlap(positions);
  assertNoDrawOutside(positions);
  final wallSize = computeSize(positions);
  return WallBlueprint(stonesPosition: positions, size: wallSize);
}