OsmosConfig.fromMap constructor

OsmosConfig.fromMap(
  1. Map<String, dynamic> map
)

Implementation

factory OsmosConfig.fromMap(Map<String, dynamic> map) {
  return OsmosConfig(
    clientId: map['clientId'] as String,
    debug: map['debug'] as bool,
    shareAdvertisingId: map['shareAdvertisingId'] as bool,
    displayAdsHost: map['displayAdsHost'] as String,
    productAdsHost: map['productAdsHost'] as String,
    eventTrackingHost: map['eventTrackingHost'] as String,

    // Set event batch processing permission
    enableBatchProcessing: map['enableBatchProcessing'] as bool,
    // Set batch processing variables
    maxEventsPerBatch: map['maxEventsPerBatch'] as int,
    maxTimeInterval: map['maxTimeInterval'] as int,
    maxRetryCount: map['maxRetryCount'] as int
  );
}