populateChartPoints method

  1. @override
void populateChartPoints({
  1. List<ChartDataPointType>? positions,
  2. List<List<num>>? yLists,
})
override

Method excepts BoxAndWhiskerSeries, and stacking series.

Implementation

@override
void populateChartPoints({
  List<ChartDataPointType>? positions,
  List<List<num>>? yLists,
}) {
  if (yLists == null) {
    yLists = <List<num>>[highValues, lowValues, openValues, closeValues];
    positions = <ChartDataPointType>[
      ChartDataPointType.high,
      ChartDataPointType.low,
      ChartDataPointType.open,
      ChartDataPointType.close,
    ];
  } else {
    yLists.add(highValues);
    yLists.add(lowValues);
    yLists.add(openValues);
    yLists.add(closeValues);
    positions!.add(ChartDataPointType.high);
    positions.add(ChartDataPointType.low);
    positions.add(ChartDataPointType.open);
    positions.add(ChartDataPointType.close);
  }

  super.populateChartPoints(positions: positions, yLists: yLists);
}