DataWalker<T> class abstract

Class to organise supply of indices

Implementers

Constructors

DataWalker({int length = 0, int repeats = 1, bool isRandom = false, Random? random, Object? source})
The constructor

Properties

currentNo int
Current index
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
isFinished bool
Flag showing there is no more iteration to go
getter/setter pair
isRandom bool
Get random index rather than increase sequentially
latefinal
lastNo int
Last index
latefinal
lastRepeatNo int
Last repeat index
latefinal
length int
Number of sequential steps or the value for random.nextInt()
final
random Random
Random number generator
latefinal
repeatNo int
Current repeat number
getter/setter pair
repeats int
How many times to repeat length increments
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
source Object?
Anything to store for sub-classes
final

Methods

current() → T
Get the current value
next([bool isNext = true]) → T
Abstract: move to the next value
nextNo([bool isNext = true]) int
Set currentNo to the next value Increase repeatNo when currentNo reaches length and reset currentNo Returns -1 when repeatNo reaches repeats
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
reset() → void
Reset currentNo and repeatNo
toString() String
A string representation of this object.
inherited

Operators

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