public class BulkUpdaterBuilder
extends java.lang.Object
BulkUpdater
concrete implementations.
You can configure here how your bulk updater should behave.
Please remember that if you want to change those settings in a future, you will need to build a new object.
"Don't let your device's pending_settings be pending settings.
Yesterday you said tomorrow,
So just do it. Yes you can! "
- Shia LeBeaconConstructor and Description |
---|
BulkUpdaterBuilder(android.content.Context context)
Public constructor for
BulkUpdater concrete object. |
Modifier and Type | Method and Description |
---|---|
BulkUpdater |
build()
If you are done configuring the bulk updater, use this method to construct concrete object.
|
BulkUpdaterBuilder |
withCloudFetchInterval(long interval,
java.util.concurrent.TimeUnit unit)
Sets how often should bulk updater sync data from cloud.
|
BulkUpdaterBuilder |
withFirmwareUpdate()
Allows bulk updater to update firmware of devices.
|
BulkUpdaterBuilder |
withRetryCount(int retryCount)
Specifies how many retries should BU take to update each device.
|
BulkUpdaterBuilder |
withTimeout(long timeoutMillis)
Sets time after bulk uopdater should end it's job.
|
public BulkUpdaterBuilder(android.content.Context context)
BulkUpdater
concrete object.
You should configure it's behaviour here and utilize built object.context
- app context needed for establishing connection to scanned devices.public BulkUpdaterBuilder withFirmwareUpdate()
public BulkUpdaterBuilder withRetryCount(int retryCount)
retryCount
- number of retriespublic BulkUpdaterBuilder withTimeout(long timeoutMillis)
timeoutMillis
- timeout in millisecondspublic BulkUpdaterBuilder withCloudFetchInterval(long interval, java.util.concurrent.TimeUnit unit)
public BulkUpdater build()