ListWheelChildBuilderDelegate class

A delegate that supplies children for ListWheelScrollView using a builder callback.

ListWheelScrollView lazily constructs its children to avoid creating more children than are visible through the Viewport. This delegate provides children using an IndexedWidgetBuilder callback, so that the children do not have to be built until they are displayed.

Inheritance

Constructors

ListWheelChildBuilderDelegate({@required IndexedWidgetBuilder builder, int childCount })
Constructs the delegate from a builder callback.

Properties

builder IndexedWidgetBuilder
Called lazily to build children.
final
childCount int
If non-null, childCount is the maximum number of children that can be provided, and children are available from 0 to childCount - 1. [...]
final
estimatedChildCount int
Returns an estimate of the number of children this delegate will build.
read-only, override
hashCode int
The hash code for this object. [...]
read-only, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

build(BuildContext context, int index) Widget
Return the child at the given index. If the child at the given index does not exist, return null.
override
shouldRebuild(covariant ListWheelChildBuilderDelegate oldDelegate) bool
Called to check whether this and the old delegate are actually 'different', so that the caller can decide to rebuild or not.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() String
Returns a string representation of this object.
inherited
trueIndexOf(int index) int
Returns the true index for a child built at a given index. Defaults to the given index, however if the delegate is ListWheelChildLoopingListDelegate, this value is the index of the true element that the delegate is looping to. [...]
inherited

Operators

operator ==(dynamic other) bool
The equality operator. [...]
inherited