Development Guides
To use data collector service and its features, the DataCollector client instance needs to be created.
The initialize method will only need to be called once.
DataCollector Client Initialization
Import module, create a new instance of builder and set all needed data then initialize.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | |
Note
- setDeviceId("#DEVICE_ID#") is optional, device id will be automatically generated in event if it is not set.
- setBackgroundCollectingEnabled(true) will enable data collection, and set the value to false will disable data collection.
- setTripDetectionEnabled(true) is optional, auto trip detection is enabled by default. This setting will control auto trip detection, and set the value to false will disable auto trip detection.
API Reference
Methods
Initialize data collector with proper data:
1 | |
You can pause and resume when it needed:
1 2 | |
To turn off data collector by using shutdown method:
1 | |