-
@Serializable() public final class MiscConfiguration
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classMiscConfiguration.Companion
-
Field Summary
Fields Modifier and Type Field Description private final MetadataCollectionConfigurationcollectMetadataprivate final BooleansdkEnabledprivate final DoubledefaultSessionTimeoutSecondsprivate final DoubleautoStopAfterDropoffSecondsprivate final LongdataUploadIntervalSecondsprivate final LongdataPushDelayIntervalSecondsprivate final LongflushIntervalSecondsprivate final IntegerflushBatchSizeprivate final BooleanbinaryEncodingprivate final BooleandualTimestampprivate final LongpendingBatchesMaxBytesprivate final LongpendingBatchesMaxAgeMsprivate final IntegerpendingBatchesMaxCount
-
Constructor Summary
Constructors Constructor Description MiscConfiguration(MetadataCollectionConfiguration collectMetadata, Boolean sdkEnabled, Double defaultSessionTimeoutSeconds, Double autoStopAfterDropoffSeconds, Long dataUploadIntervalSeconds, Long dataPushDelayIntervalSeconds, Long flushIntervalSeconds, Integer flushBatchSize, Boolean binaryEncoding, Boolean dualTimestamp, Long pendingBatchesMaxBytes, Long pendingBatchesMaxAgeMs, Integer pendingBatchesMaxCount)
-
Method Summary
Modifier and Type Method Description final MetadataCollectionConfigurationgetCollectMetadata()final BooleangetSdkEnabled()Server-driven master switch. final DoublegetDefaultSessionTimeoutSeconds()final DoublegetAutoStopAfterDropoffSeconds()Server-side default for the post-dropoff auto-stop wind-down timer, in seconds. final LonggetDataUploadIntervalSeconds()final LonggetDataPushDelayIntervalSeconds()final LonggetFlushIntervalSeconds()final IntegergetFlushBatchSize()final BooleangetBinaryEncoding()When true, the SDK sends DSDP v2 binary payloads (S-011) instead of JSON. final BooleangetDualTimestamp()When true, every sample emits both wallClockTimestamp (capture-time unix epoch seconds) and sensorTimestamp (native sensor / boot-relative clock) (S-001). final LonggetPendingBatchesMaxBytes()Total byte ceiling for the on-disk pending-batches store. final LonggetPendingBatchesMaxAgeMs()Maximum age of a persisted batch before it's pruned. final IntegergetPendingBatchesMaxCount()Hard cap on the number of persisted batches. -
-
Constructor Detail
-
MiscConfiguration
MiscConfiguration(MetadataCollectionConfiguration collectMetadata, Boolean sdkEnabled, Double defaultSessionTimeoutSeconds, Double autoStopAfterDropoffSeconds, Long dataUploadIntervalSeconds, Long dataPushDelayIntervalSeconds, Long flushIntervalSeconds, Integer flushBatchSize, Boolean binaryEncoding, Boolean dualTimestamp, Long pendingBatchesMaxBytes, Long pendingBatchesMaxAgeMs, Integer pendingBatchesMaxCount)
-
-
Method Detail
-
getCollectMetadata
final MetadataCollectionConfiguration getCollectMetadata()
-
getSdkEnabled
final Boolean getSdkEnabled()
Server-driven master switch. When
false, the SDK refuses to start a new session —startDeliveryByX(...)callbacks fire with com.doorstepai.sdks.tracking.internal.SdkError.SdkDisabled and nonewSessionrequest is made. Defaults totrueso older config responses (without the field) keep working unchanged. Honored immediately on the nextensureLoaded().
-
getDefaultSessionTimeoutSeconds
final Double getDefaultSessionTimeoutSeconds()
-
getAutoStopAfterDropoffSeconds
final Double getAutoStopAfterDropoffSeconds()
Server-side default for the post-dropoff auto-stop wind-down timer, in seconds. When non-null (and 0), the SDK will automatically call com.doorstepai.sdks.tracking.DoorstepAI.stopDelivery this many seconds after com.doorstepai.sdks.tracking.DoorstepAI.markDropoff is invoked, unless the host explicitly passed a value to com.doorstepai.sdks.tracking.DoorstepAI.init (which always wins).
The timer is backed by android.app.AlarmManager with
setAndAllowWhileIdle, so it is Doze-safe and reliable for long values (tens of minutes to hours).
-
getDataUploadIntervalSeconds
final Long getDataUploadIntervalSeconds()
-
getDataPushDelayIntervalSeconds
final Long getDataPushDelayIntervalSeconds()
-
getFlushIntervalSeconds
final Long getFlushIntervalSeconds()
-
getFlushBatchSize
final Integer getFlushBatchSize()
-
getBinaryEncoding
final Boolean getBinaryEncoding()
When true, the SDK sends DSDP v2 binary payloads (S-011) instead of JSON. Default
falseso older server builds receive JSON unchanged.
-
getDualTimestamp
final Boolean getDualTimestamp()
When true, every sample emits both wallClockTimestamp (capture-time unix epoch seconds) and sensorTimestamp (native sensor / boot-relative clock) (S-001). Default
falseso older server builds receive only the legacytimestampfield.
-
getPendingBatchesMaxBytes
final Long getPendingBatchesMaxBytes()
Total byte ceiling for the on-disk pending-batches store. Once exceeded, the pruner drops oldest batches first. Mirrors iOS's
maxPendingBatchesTotalBytes = 16 MBbut defaults higher on Android because we have private app storage rather than a sandbox file. Set to 0 to disable the byte budget.
-
getPendingBatchesMaxAgeMs
final Long getPendingBatchesMaxAgeMs()
Maximum age of a persisted batch before it's pruned. Sensor data older than the default (24 h) is rarely useful for delivery analysis. 0 disables the age budget.
-
getPendingBatchesMaxCount
final Integer getPendingBatchesMaxCount()
Hard cap on the number of persisted batches. Mirrors iOS's
maxPendingBatchesCount = 240. 0 disables the count budget.
-
-
-
-