FakeTrackingController class final
In-memory implementation of the normal host facade.
It is intentionally deterministic and supports the complete lifecycle used by widget tests. Export data is represented by a fake path and route maps contain the points injected through emitPoint.
- Implemented types
Constructors
- FakeTrackingController({required TrackingOwner owner, DateTime clock()?, TrackingReadiness? readiness})
Properties
-
activityStream
→ Stream<
ActivitySnapshot> -
no setteroverride
-
calls
→ List<
FakeTrackingCall> -
final
- currentActivity → ActivitySnapshot
-
no setteroverride
- currentOwner → TrackingOwner
-
no setteroverride
- currentSession → TrackingSessionSnapshot
-
no setteroverride
- currentStatus → TrackerStatus
-
no setteroverride
- hashCode → int
-
The hash code for this object.
no setterinherited
- isInitialized → bool
-
no setteroverride
-
pointStream
→ Stream<
TrackPoint> -
no setteroverride
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
sessionStream
→ Stream<
TrackingSessionSnapshot> -
no setteroverride
-
statusStream
→ Stream<
TrackerStatus> -
no setteroverride
- supportsPagedHistory → bool
-
no setteroverride
-
trackHistoryEvents
→ Stream<
TrackHistoryEvent> -
no setteroverride
Methods
-
acknowledgeReadinessEducation(
String issueCode) → Future< TrackingReadiness> -
override
-
capabilities(
) → Future< TrackingCapabilityReport> -
override
-
checkReadiness(
) → Future< TrackingReadiness> -
override
-
completeCurrentTrack(
{String reason = 'user_completed'}) → Future< TrackLifecycleResult> -
override
-
completeTrack(
{String? trackId, String reason = 'user_completed', String? operationId}) → Future< void> -
override
-
deleteTrack(
String trackId) → Future< void> -
override
-
dispose(
) → Future< void> -
override
-
emitActivity(
ActivitySnapshot activity) → void -
emitPoint(
{required double latitude, required double longitude, bool accepted = true}) → TrackPoint -
exportTrack(
{required String trackId, required TrackExportFormat format, TrackExportOptions options = const TrackExportOptions(), String? fileName}) → Future< TrackExportResult> -
override
-
getTrack(
String trackId) → Future< Track?> -
override
-
initialize(
) → Future< void> -
override
-
listTrackPage(
TrackQuery query) → Future< TrackPage> -
override
-
loadTrackBundle(
String trackId) → Future< TrackBundle> -
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
openSettings(
TrackingSettingsDestination destination) → Future< TrackingSettingsResult> -
override
-
pauseCurrentTrack(
{String reason = 'user_paused'}) → Future< TrackLifecycleResult> -
override
-
pauseTrack(
{String? trackId, String reason = 'user_paused', String? operationId}) → Future< void> -
override
-
permissions(
{bool request = false}) → Future< TrackingPermissionState> -
override
-
requestNextPermission(
) → Future< TrackingReadiness> -
override
-
resolveOwnerConflict(
OwnerConflictResolutionRequest request) → Future< OwnerConflictResolutionResult> -
override
-
resumeCurrentTrack(
) → Future< TrackStartResult> -
override
-
resumeTrack(
String trackId) → Future< void> -
override
-
seedInterruptedTrack(
{String trackId = 'fake-interrupted-track', String? routeId, TrackingConfig config = const TrackingConfig()}) → Track - Seeds a resumable interrupted route to simulate process restoration.
-
setReadiness(
TrackingReadiness readiness) → void -
startNewTrack(
TrackStartRequest request) → Future< TrackStartResult> -
override
-
startOrRecoverTrack(
TrackStartRequest request) → Future< TrackStartResult> -
override
-
startTrack(
{required String userId, required String organizationId, String? routeId, String? requestedTrackId, TrackingConfig? config}) → Future< String> -
override
-
switchOwner(
TrackingOwner next, {OwnerSwitchPolicy policy = OwnerSwitchPolicy.rejectIfResumable}) → Future< OwnerSwitchResult> -
override
-
toString(
) → String -
A string representation of this object.
inherited
-
updateTrackingConfig(
TrackingConfig config) → Future< TrackingConfigurationUpdateResult> -
override
-
watchCurrentTrack(
) → Stream< Track?> -
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited