GeofenceService class
A class provides geofence management and geo-fencing.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- isRunningService → bool
-
Returns whether the service is running.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
addActivityChangeListener(
ActivityChanged listener) → void - Register a closure to be called when the Activity changes.
-
addGeofence(
Geofence geofence) → void - Add geofence.
-
addGeofenceList(
List< Geofence> geofenceList) → void - Add geofence list.
-
addGeofenceStatusChangeListener(
GeofenceStatusChanged listener) → void - Register a closure to be called when the GeofenceStatus changes.
-
addLocationChangeListener(
LocationChanged listener) → void - Register a closure to be called when the Location changes.
-
addLocationServicesStatusChangeListener(
ValueChanged< bool> listener) → void - Register a closure to be called when the location services status changes.
-
addStreamErrorListener(
ValueChanged listener) → void - Register a closure to be called when a stream error occurs.
-
clearAllListeners(
) → void - Clears all listeners registered with the service.
-
clearGeofenceList(
) → void - Clear geofence list.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
pause(
) → void - Pause GeofenceService.
-
removeActivityChangeListener(
ActivityChanged listener) → void - Remove a previously registered closure from the list of closures that are notified when the Activity changes.
-
removeGeofence(
Geofence geofence) → void - Remove geofence.
-
removeGeofenceById(
String id) → void -
Remove geofence by
id
. -
removeGeofenceList(
List< Geofence> geofenceList) → void - Remove geofence list.
-
removeGeofenceStatusChangeListener(
GeofenceStatusChanged listener) → void - Remove a previously registered closure from the list of closures that are notified when the GeofenceStatus changes.
-
removeLocationChangeListener(
LocationChanged listener) → void - Remove a previously registered closure from the list of closures that are notified when the Location changes.
-
removeLocationServicesStatusChangeListener(
ValueChanged< bool> listener) → void - Remove a previously registered closure from the list of closures that are notified when the location services status changes.
-
removeStreamErrorListener(
ValueChanged listener) → void - Remove a previously registered closure from the list of closures that are notified when a stream error occurs.
-
resume(
) → void - Resume GeofenceService.
-
setup(
{int? interval, int? accuracy, int? loiteringDelayMs, int? statusChangeDelayMs, bool? useActivityRecognition, bool? allowMockLocations, bool? printDevLog, GeofenceRadiusSortType? geofenceRadiusSortType}) → GeofenceService - Setup GeofenceService. Some options do not change while the service is running.
-
start(
[List< Geofence> ? geofenceList]) → Future<void> -
Start GeofenceService.
It can be initialized with
geofenceList
. -
stop(
) → Future< void> - Stop GeofenceService. Note that the registered geofence list is cleared when this function is called.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- instance → GeofenceService
-
Instance of GeofenceService.
final