SeatController.fromInts constructor
SeatController.fromInts({})
Convenience factory that wraps a legacy integer grid.
Integer encoding: 0 = gap, 1 = available, 2 = booked, 3 = disabled. All seats default to SeatType.economy.
Implementation
factory SeatController.fromInts({
required List<List<int>> seatGrid,
int maxSelection = 5,
Map<SeatType, double> prices = const {},
List<SeatPoint> initialSelection = const [],
}) {
_validateIntGrid(seatGrid);
return SeatController(
seatGrid: Seat.gridFromInts(seatGrid),
maxSelection: maxSelection,
prices: prices,
initialSelection: initialSelection,
);
}