MethodChannelMoveSdk class

An implementation of MovesdkPlatform that uses method channels.

Inheritance

Constructors

MethodChannelMoveSdk()

Properties

authStateChannel EventChannel
final
configChangeChannel EventChannel
final
deviceDiscoveryChannel EventChannel
final
deviceScannerChannel EventChannel
final
deviceStateChannel EventChannel
final
hashCode int
The hash code for this object.
no setterinherited
logChannel EventChannel
final
methodChannel MethodChannel
The method channel used to interact with the native platform.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sdkStateChannel EventChannel
final
serviceErrorChannel EventChannel
final
serviceWarningChannel EventChannel
final
tripStartChannel EventChannel
final
tripStateChannel EventChannel
final

Methods

allowMockLocations(bool allow) Future<void>
Android only
override
callbackHandler(MethodCall methodCall) Future
deleteLocalData() Future<void>
Deletes all the collected user SDK data stored on the device. This doesn't affect the SDK state.
override
fetchUserConfig() Future<void>
Force fetching config from server.
override
finishCurrentTrip() Future<void>
Ends the current ongoing trip.
override
forceTripRecognition() Future<void>
Temporarily calibrates the SDK to highest detection mode.
override
geocode(double latitude, double longitude) Future<MoveGeocodeResult>
Geocode address lookup at coordinates: (latitude, longitude) Returns a result with a String at MoveGeocodeResult.result or an error with MoveGeocodeResult.error.
override
getAuthState() Future<MoveAuthState>
Returns the current authorization state.
override
getDeviceQualifier() Future<String>
Get a unique Device Identifier to distinguish the device. This changes when a device is cloned. Returns a unique device identifier.
override
getErrors() Future<List<MoveServiceError>>
Gets the current SDK failures Returns current service state. Empty if all good.
override
getMoveVersion() Future<String>
Get Move SDK Version. Returns a version string.
override
getPlatformVersion() Future<String>
override
getRegisteredDevices() Future<List<MoveDevice>>
Get a list of devices registered with the sdk to be scanned for during trip.
override
getState() Future<MoveState>
Returns the current SDK state.
override
getTripState() Future<MoveTripState>
Returns the current SDK trip state.
override
getWarnings() Future<List<MoveServiceWarning>>
Gets the current SDK warniings Returns current service state. Empty if all good.
override
ignoreCurrentTrip() Future<void>
Ignores the current ongoing trip.
override
init() Future<void>
override
initiateAssistanceCall() Future<MoveAssistanceCallStatus>
Inititate an Assistance Call to emergency services. Returns a status wether the call succeeded.
override
keepActive(bool enabled) Future<void>
Android only
override
keepInForeground(bool enabled) Future<void>
Android only
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
recognitionNotification(MoveNotification notification) Future<void>
Setup notification for Move SDK recognition
override
registerDevices(List<MoveDevice> devices) Future<void>
Register devices with the sdk to be scanned for during trip. All will be unregistered on shutdown.
override
resolveError() Future<void>
Resolve standing SDK state error. Host app should call this API after resolving the raised errors. SDK will reevaluate the error state and update the SDK state accordingly.
override
setAssistanceMetaData(String? assistanceMetadataValue) Future<void>
Set metadata to be sent with assistance call or impact detection.
override
setAuthStateListener() Stream<MoveAuthState>
Set a block to be invoked every time SDK authorization state changes. Important:
override
setDeviceDiscoveryListener() Stream<List<MoveScanResult>>
Device listener fired on device scans during trips.
override
setDeviceStateListener() Stream<List<MoveDevice>>
Device state fired on device connection change.
override
setLiveLocationTag(String? tag) Future<bool>
override
setLogListener() Stream<String>
Set callback to be invoked every time a new SDK log event occurs. Returns log string. Invoked every time log event occurs.
override
setRemoteConfigChangeListener() Stream<MoveConfig>
Set a listener when the config changed in response to the useBackendConfig option.
override
setSdkStateListener() Stream<MoveState>
Set a block to be invoked every time SDK state changes. Important:
override
setServiceErrorListener() Stream<List<MoveServiceError>>
Set a block to be invoked every time SDK warning status changes. When the config passed in setup(auth:config:) tries to initialize services that are not available in the server config those services will stop and are reported in the to the provided listener. This is not supposed to happen in a correct setup. Additionally missing user permissions are also reported. Returns stream: List<MoveServiceError>. Invoked in case of configuration or permission errors.
override
setServiceWarningListener() Stream<List<MoveServiceWarning>>
Sets a block to get called when optional permissions for the activated services are missing. Returns stream: List<MoveServiceWarning>. Invoked in case of configuration or permission errors.
override
setTripStartListener() Stream<DateTime>
Set a block to be invoked when a trip starts. Returns stream with the trip start date. The listener is sent delayed after confirming a trip is valid, around 30s to 130s.
override
setTripStateListener() Stream<MoveTripState>
Set a block to be invoked every time SDK trip state changes. Returns stream: latest SDK trip state. Invoked every time SDK trip state changes.
override
setup(MoveAuth moveAuth, MoveConfig moveConfig, MoveOptions? options) Future<void>
The SDK will setup and authenticate a user. moveAuth contains authentication data and tokens prepared by the app backend.. moveConfig indicates the configuration of the services which will be running. Services in moveConfig must be enabled in the MOVE dashboard.
override
setupWithCode(String authCode, MoveConfig moveConfig, MoveOptions? options) Future<MoveAuthResult>
The SDK will setup and authenticate a user. authCode Auth code to setup with.. Services in moveConfig must be enabled in the MOVE dashboard.
override
shutdown({bool force = true}) Future<MoveShutdownResult>
Shutdown SDK shared instance.
override
startAutomaticDetection() Future<bool>
Starts the required detection services stated in the Config that is passed on init. Starting the service will set the SDK to running state. Precondition:
override
startScanningDevices({List<MoveDeviceFilter> filter = const [MoveDeviceFilter.paired], String? uuid, int? manufacturerId}) Stream<List<MoveDevice>>
Starts scanning for devices that can be registered with the sdk Scan can be filtered with filter, default includes only paired devices for scanning beacons uuid and manufacturerId must be specified
override
startTrip(Map<String, String>? metadata) Future<bool>
Start manual trip
override
stopAutomaticDetection() Future<bool>
Stops the automatic detection service. Stoping the service will set the SDK State back to ready. Precondition:
override
synchronizeUserData() Future<bool>
Force sending all pending user data to server. Preconditions:
override
toString() String
A string representation of this object.
inherited
tripNotification(MoveNotification notification) Future<void>
Setup trip notification
override
unregisterDevices(List<MoveDevice> devices) Future<void>
Unregister devices with the sdk to be scanned for during trip
override
updateAuth(MoveAuth moveAuth) Future<MoveAuthError?>
Updates the user's provided Auth upon its expiry. Auth expiry triggers the SDK Auth State change listener.
override
updateConfig(MoveConfig config) Future<void>
The SDK will attempt to change the client config, will call warning/error listener respectively.
override
walkingLocationNotification(MoveNotification notification) Future<void>
Setup walking location notification
override

Operators

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