BarSeries<T, D> constructor

BarSeries<T, D>({
  1. ValueKey<String>? key,
  2. ChartSeriesRendererFactory<T, D>? onCreateRenderer,
  3. required List<T> dataSource,
  4. required ChartValueMapper<T, D> xValueMapper,
  5. required ChartValueMapper<T, num> yValueMapper,
  6. ChartValueMapper<T, dynamic>? sortFieldValueMapper,
  7. ChartValueMapper<T, Color>? pointColorMapper,
  8. ChartValueMapper<T, String>? dataLabelMapper,
  9. SortingOrder? sortingOrder,
  10. bool isTrackVisible = false,
  11. String? xAxisName,
  12. String? yAxisName,
  13. String? name,
  14. Color? color,
  15. double? width,
  16. double spacing = 0,
  17. MarkerSettings? markerSettings,
  18. EmptyPointSettings? emptyPointSettings,
  19. DataLabelSettings? dataLabelSettings,
  20. bool? isVisible,
  21. LinearGradient? gradient,
  22. LinearGradient? borderGradient,
  23. BorderRadius borderRadius = const BorderRadius.all(Radius.zero),
  24. bool? enableTooltip,
  25. double? animationDuration,
  26. Color trackColor = Colors.grey,
  27. Color trackBorderColor = Colors.transparent,
  28. double trackBorderWidth = 1,
  29. double trackPadding = 0,
  30. List<Trendline>? trendlines,
  31. Color? borderColor,
  32. double? borderWidth,
  33. SelectionSettings? selectionSettings,
  34. SelectionBehavior? selectionBehavior,
  35. bool? isVisibleInLegend,
  36. LegendIconType? legendIconType,
  37. String? legendItemText,
  38. double? opacity,
  39. List<double>? dashArray,
  40. SeriesRendererCreatedCallback? onRendererCreated,
  41. List<int>? initialSelectedDataIndexes,
})

Creating an argument constructor of BarSeries class.

Implementation

BarSeries(
    {ValueKey<String>? key,
    ChartSeriesRendererFactory<T, D>? onCreateRenderer,
    required List<T> dataSource,
    required ChartValueMapper<T, D> xValueMapper,
    required ChartValueMapper<T, num> yValueMapper,
    ChartValueMapper<T, dynamic>? sortFieldValueMapper,
    ChartValueMapper<T, Color>? pointColorMapper,
    ChartValueMapper<T, String>? dataLabelMapper,
    SortingOrder? sortingOrder,
    this.isTrackVisible = false,
    String? xAxisName,
    String? yAxisName,
    String? name,
    Color? color,
    double? width,
    this.spacing = 0,
    MarkerSettings? markerSettings,
    EmptyPointSettings? emptyPointSettings,
    DataLabelSettings? dataLabelSettings,
    bool? isVisible,
    LinearGradient? gradient,
    LinearGradient? borderGradient,
    this.borderRadius = const BorderRadius.all(Radius.zero),
    bool? enableTooltip,
    double? animationDuration,
    this.trackColor = Colors.grey,
    this.trackBorderColor = Colors.transparent,
    this.trackBorderWidth = 1,
    this.trackPadding = 0,
    List<Trendline>? trendlines,
    Color? borderColor,
    double? borderWidth,
    // ignore: deprecated_member_use_from_same_package
    SelectionSettings? selectionSettings,
    SelectionBehavior? selectionBehavior,
    bool? isVisibleInLegend,
    LegendIconType? legendIconType,
    String? legendItemText,
    double? opacity,
    List<double>? dashArray,
    SeriesRendererCreatedCallback? onRendererCreated,
    List<int>? initialSelectedDataIndexes})
    : super(
          key: key,
          onCreateRenderer: onCreateRenderer,
          name: name,
          onRendererCreated: onRendererCreated,
          xValueMapper: xValueMapper,
          yValueMapper: yValueMapper,
          sortFieldValueMapper: sortFieldValueMapper,
          pointColorMapper: pointColorMapper,
          dataLabelMapper: dataLabelMapper,
          dataSource: dataSource,
          xAxisName: xAxisName,
          yAxisName: yAxisName,
          color: color,
          trendlines: trendlines,
          width: width ?? 0.7,
          markerSettings: markerSettings,
          dataLabelSettings: dataLabelSettings,
          emptyPointSettings: emptyPointSettings,
          isVisible: isVisible,
          gradient: gradient,
          borderGradient: borderGradient,
          enableTooltip: enableTooltip,
          animationDuration: animationDuration,
          borderColor: borderColor,
          borderWidth: borderWidth,
          selectionSettings: selectionSettings,
          selectionBehavior: selectionBehavior,
          legendItemText: legendItemText,
          isVisibleInLegend: isVisibleInLegend,
          legendIconType: legendIconType,
          sortingOrder: sortingOrder,
          opacity: opacity,
          initialSelectedDataIndexes: initialSelectedDataIndexes,
          dashArray: dashArray);