InjectedScrollingImp class

Implementation of InjectedScrolling

Inheritance
Mixed-in types
Available extensions

Constructors

InjectedScrollingImp({double initialScrollOffset = 0.0, bool keepScrollOffset = true, OnScroll? onScroll, int onScrollEndedDelay = 300})

Properties

autoDisposeWhenNotUsed bool
finalinherited
completer Completer?
getter/setter pairinherited
connectionState ConnectionState
no setterinherited
controller ScrollController
The created ScrollController
no setteroverride
creator Object? Function()
finalinherited
customStatus Object?
Custom status of the state. Set manually to mark the state with a particular tag to be used in your logic.
getter/setter pairinherited
error → dynamic
The error
no setterinherited
hasData bool
The state is mutated successfully.
no setterinherited
hasEndedScrolling bool
The scrolling list has just ended scrolling.
getter/setter pairinherited
hasError bool
The stats has error
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
hasObservers bool
Whether the state has listeners or not
no setterinherited
hasReachedMaxExtent bool
The scroll list has reached its bottom (the current offset is greater or equal then maxScrollExtent)
getter/setter pairinherited
hasReachedMinExtent bool
The scroll list has reached its top (the current offset is less or equal then minScrollExtent)
getter/setter pairinherited
hasStartedScrolling bool
This scrolling list has just started scrolling.
getter/setter pairinherited
hasStartedScrollingForward bool
The scrolling list has just started scrolling in the forward direction.
getter/setter pairinherited
hasStartedScrollingReverse bool
The scrolling list has just started scrolling in the reverse direction.
getter/setter pairinherited
initialScrollOffset double
Initial scroll offset
final
initialSnapState SnapState<double>
no setterinherited
initialState double?
getter/setter pairinherited
isDone bool
The state is mutated using a stream and the stream is done.
no setterinherited
isIdle bool
The state is initialized and never mutated.
no setterinherited
isInitialized bool
getter/setter pairinherited
isScrolling bool
Whether the associates Scroll view is scrolling.
getter/setter pairinherited
isScrollingForward bool
Scrolling is happening in the positive scroll offset direction.
no setterinherited
isScrollingReverse bool
Scrolling is happening in the negative scroll offset direction.
no setterinherited
isStateInitialized bool
no setterinherited
isWaiting bool
The state is waiting for and asynchronous task to end.
no setterinherited
isWaitingToInitialize bool
getter/setter pairinherited
keepScrollOffset bool
similar to ScrollController.keepScrollOffset
final
maxScrollExtent double
The maximum in-range value for pixels.
no setterinherited
minScrollExtent double
The minimum in-range value for pixels.
no setterinherited
mockableCreator Object? Function()
no setterinherited
observerLength int
no setterinherited
offset double
The current offset
no setterinherited
oldSnapState SnapState<double>?
no setterinherited
onScroll OnScroll?
final
onScrollEndedDelay int
final
position ScrollPosition
no setter
rebuild → _Rebuild

Available on InjectedScrolling, provided by the InjectedScrollingX extension

Listen to InjectedScrolling
no setter
removeFromReactiveModel VoidCallback?
getter/setter pairinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
snapState SnapState<double>
A snap representation of the state
no setterinherited
snapValue SnapState<double>
getter/setter pairinherited
state double
the current fraction scroll position. It's between 0 (min) and 1 (max position)
getter/setter pairinherited-getteroverride-setter
stateAsync Future<double>
The current Async state
getter/setter pairinherited
stateInterceptorGlobal StateInterceptor<double>?
finalinherited
subscription StreamSubscription?
It is not null if the state is waiting for a Future or is subscribed to a Stream
getter/setter pairinherited

Methods

addCleaner(VoidCallback listener) VoidCallback
Add a callback to be executed when the state is disposed of.
inherited
addObserver({required ObserveReactiveModel listener, bool shouldAutoClean = false, bool isSideEffects = true}) VoidCallback
Add observer to this state.
inherited
cleanState() → void
Clean the state
inherited
dispose() → void
Dispose the state
override
disposeIfNotUsed() → void
Dispose the state if it has no listener
inherited
initialize() → void
inherited
initializeState() FutureOr<double?>
Initialize the state
inherited
interceptState(SnapState<double> snap, StateInterceptor<double>? stateInterceptor) SnapState<double>?
inherited
middleSetCreator(StateStatus status, Object? result) → void
inherited
middleSetState(StateStatus status, Object? result, {SideEffects<double>? sideEffects, StateInterceptor<double>? stateInterceptor, bool shouldOverrideDefaultSideEffects(SnapState<double>)?}) → dynamic
inherited
moveTo(double to, {Duration? duration, Curve? curve, bool? clamp = true}) Future<void>
Calls ScrollPosition.jumpTo if duration is null or Duration.zero, otherwise ScrollPosition.animateTo is called.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notify({SnapState<double>? nextSnap, SideEffects<double>? sideEffects, bool shouldOverrideDefaultSideEffects(SnapState<double>)?, StateInterceptor<double>? stateInterceptor}) bool
Notify observers
inherited
onAll<R>({R onIdle()?, required R onWaiting()?, required R onError(dynamic error, VoidCallback refreshError)?, required R onData(double data)}) → R
Listen to the injected Model and rebuild when it emits a notification.
inherited
onOrElse<R>({R onIdle()?, R onWaiting()?, R onError(dynamic error, VoidCallback refreshError)?, R onData(double data)?, required R orElse(double data)}) → R
Listen to the injected Model and rebuild when it emits a notification.
inherited
onStateInitialized() → void
inherited
rebuildState() → void
inherited
refresh() Future<double?>
Refresh the Injected state. Refreshing the state means reinitialize it and reinvoke its creation function and notify its listeners.
inherited
resetDefaultState() → void
inherited
setState(Object? mutator(double s), {SideEffects<double>? sideEffects, StateInterceptor<double>? stateInterceptor, bool shouldOverrideDefaultSideEffects(SnapState<double> snap)?, int debounceDelay = 0, int throttleDelay = 0}) Future<double?>
Mutate the state of the model and notify observers.
inherited
setStateNullable(Object? mutator(double? s), {required void middleSetState(StateStatus, dynamic result), required StackTrace? stackTrace}) FutureOr<double?>
inherited
setToHasData(dynamic data, {SideEffects<double>? sideEffects, bool shouldOverrideDefaultSideEffects(SnapState<double>)?, StateInterceptor<double>? stateInterceptor}) → void
Set the state to the data status
inherited
setToHasError(dynamic error, {StackTrace? stackTrace, VoidCallback? refresher, SideEffects<double>? sideEffects, bool shouldOverrideDefaultSideEffects(SnapState<double>)?, StateInterceptor<double>? stateInterceptor}) → void
Set the state to the error status
inherited
setToIsIdle([Object? data]) → void
Set the state to the idle status
inherited
setToIsWaiting({SideEffects<double>? sideEffects, bool shouldOverrideDefaultSideEffects(SnapState<double>)?, StateInterceptor<double>? stateInterceptor}) → void
Set the state to the waiting status
inherited
toString() String
A string representation of this object.
inherited
whenConnectionState<R>({R onIdle()?, required R onWaiting()?, required R onError(dynamic error)?, required R onData(double data)}) → R
inherited

Operators

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