class ProximityObserverBuilder
Builder for configuring new ProximityObserver objects.
applicationContext
- the context of your app.
cloudCredentials
- EstimoteCloudCredentials object for authorizing within Estimote Cloud.
Author
Estimote Inc. (contact@estimote.com)
ProximityObserverBuilder(applicationContext: Context, cloudCredentials: EstimoteCloudCredentials)
Builder for configuring new ProximityObserver objects. |
fun build(): ProximityObserver
Builds the configured ProximityObserver. |
|
fun onError(onErrorAction: (Throwable) -> Unit): ProximityObserverBuilder
Specifies an action to be called whenever any error occurs. If not specified, all errors will be delivered through Log.e(...) by default. |
|
fun withAnalyticsReportingDisabled(): ProximityObserverBuilder
Disables Estimote Analytics for this |
|
fun withBalancedPowerMode(): ProximityObserverBuilder
Proximity observer will use mode with balance between scan reliability and battery drainage. |
|
fun withEstimoteSecureMonitoringDisabled(): ProximityObserverBuilder
Disables Estimote Secure Monitoring resolving. When enabled, it will try to decrypt scanned encrypted packets in addition to non-secure packets. When disabled, it will only scan for non-encrypted packets. Enabled by default. |
|
fun withLowLatencyPowerMode(): ProximityObserverBuilder
Proximity observer will use the most reliable mode, but may drain battery a lot. |
|
fun withLowPowerMode(): ProximityObserverBuilder
Proximity observer will use battery efficient mode, but the scanning won't be super reliable. |
|
fun withScannerInForegroundService(notification: Notification): ProximityObserverBuilder
Will make the observation process use scanner wrapped in a foreground service. This will display notification in the user's notifications bar, but will ensure that the scanning won't be killed by the system. Your scanning will be handled without any service by default. |
|
fun withTelemetryReportingDisabled(): ProximityObserverBuilder
Disables periodical beacons' telemetry data reporting to Estimote cloud. It sends info such as battery level, temperature, or light level. Enabled by default. |