BarChartBuilder class

Creates a BarChart widget based on the JSON structure.

Constructors

BarChartBuilder({required bool? animate, required Duration? animationDuration, required BarGroupingType? barGroupingType, required BarRendererDecorator<String>? barRendererDecorator, required List<ChartBehavior<String>>? behaviors, required List<SeriesRendererConfig<String>>? customSeriesRenderers, required bool defaultInteractions, required BarRendererConfig<String>? defaultRenderer, required LinkedHashMap<String, NumericAxisSpec>? disjointMeasureAxes, required AxisSpec<String>? domainAxis, required bool? flipVerticalAxis, required LayoutConfig? layoutConfig, required NumericAxisSpec? primaryMeasureAxis, required RTLSpec? rtlSpec, required NumericAxisSpec? secondaryMeasureAxis, required List<Series<dynamic, String>> series, required List<SelectionModelConfig<String>>? selectionModels, required UserManagedState<String>? userManagedState, required bool vertical})

Properties

animate bool?
final
animationDuration Duration?
final
barGroupingType → BarGroupingType?
final
barRendererDecorator → BarRendererDecorator<String>?
final
behaviors List<ChartBehavior<String>>?
final
customSeriesRenderers List<SeriesRendererConfig<String>>?
final
defaultInteractions bool
final
defaultRenderer → BarRendererConfig<String>?
final
disjointMeasureAxes LinkedHashMap<String, NumericAxisSpec>?
final
domainAxis → AxisSpec<String>?
final
flipVerticalAxis bool?
final
hashCode int
The hash code for this object.
no setterinherited
layoutConfig → LayoutConfig?
final
numSupportedChildren int
finalinherited
preferredSizeWidget bool
finalinherited
primaryMeasureAxis → NumericAxisSpec?
final
rtlSpec → RTLSpec?
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
secondaryMeasureAxis → NumericAxisSpec?
final
selectionModels List<SelectionModelConfig<String>>?
final
series List<Series<dynamic, String>>
final
userManagedState → UserManagedState<String>?
final
vertical bool
final

Methods

build({required ChildWidgetBuilder? childBuilder, required BuildContext context, required JsonWidgetData data}) Widget
Builds the widget. If there are dynamic keys on the data object, and the widget is not a PreferredSizeWidget, then the returned widget will be wrapped by a stateful widget that will rebuild if any of the dynamic args change in value.
inherited
buildCustom({ChildWidgetBuilder? childBuilder, required BuildContext context, required JsonWidgetData data, Key? key}) Widget
Builds the widget from the give data.
getChild(JsonWidgetData? data, {int index = 0}) → JsonWidgetData
Returns a non-null child for widgets that must always have child widgets. This allows the widget to be built and rendered even if the child is missing.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
remove(JsonWidgetData data) → void
Called when a JSON widget is removed from the tree due to a conditional. Custom widgets may need to implement this to clean up values that may have been placed on the JsonWidgetRegistry by the widget.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

fromDynamic(dynamic map, {JsonWidgetRegistry? registry}) BarChartBuilder
Builds the builder from a Map-like dynamic structure. This expects the JSON format to be of the following structure:

Constants

kNumSupportedChildren → const int
type → const String