GuardObserver class abstract

Hooks into the lifecycle of the RouteNodeGuard pipeline.

Override the methods that are relevant to your use case (logging, metrics, debugging). All default implementations are no-ops and must be called via super when overridden.

Constructors

GuardObserver()
Hooks into the lifecycle of the RouteNodeGuard pipeline.
const

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
onCancel(RouteNode origin, RouteNode target, RouteNodeGuard guard) → void
Called when guard returns GuardResultCancel.
onGuard(RouteNode origin, RouteNode target, RouteNodeGuard guard) → void
Called immediately before guard is invoked.
onGuardError(RouteNode origin, RouteNode target, Object error, StackTrace stackTrace, RouteNodeGuard guard) → void
Called when guard throws error with stackTrace.
onGuardSync(GuardSyncReason reason) → void
Called when a GuardSync triggers re-evaluation with reason.
onNext(RouteNode origin, RouteNode target, RouteNodeGuard? guard) → void
Called when a guard returns GuardResultNext.
onRedirect(RouteNode origin, RouteNode target, RouteNode redirect, RouteNodeGuard? guard) → void
Called when guard returns GuardResultRedirect with redirect as the new target.
onStart(RouteNode origin, RouteNode target) → void
Called before any guard runs for a mutation from origin to target.
toString() String
A string representation of this object.
inherited

Operators

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