-
public final class OsmosSDK.Companion.BuilderBuilder class for SDK configuration. Each builder instance maintains isolated configuration state.
-
-
Constructor Summary
Constructors Constructor Description OsmosSDK.Companion.Builder()
-
Method Summary
Modifier and Type Method Description final OsmosSDK.Companion.BuilderclientId(String clientId)Sets the client ID for the SDK (required). final OsmosSDK.Companion.BuilderproductAdsHost(String host)Sets the product ads host (optional). final OsmosSDK.Companion.BuilderdisplayAdsHost(String host)Sets the display ads host (optional). final OsmosSDK.Companion.BuildereventTrackingHost(String host)Sets the event tracking host (optional). final OsmosSDK.Companion.Builderdebug(Boolean debug)Enables or disables debug mode (optional). final OsmosSDK.Companion.BuildererrorCallback(WeakReference<ErrorCallback> callback)Sets the error callback for handling initialization errors (optional). final UnitbuildGlobalInstance()Validates the configuration and initializes the SDK as singleton. final OsmosSDKbuild()Validates the configuration and creates a new SDK instance. -
-
Method Detail
-
clientId
final OsmosSDK.Companion.Builder clientId(String clientId)
Sets the client ID for the SDK (required).
- Parameters:
clientId- Unique client identifier
-
productAdsHost
final OsmosSDK.Companion.Builder productAdsHost(String host)
Sets the product ads host (optional).
- Parameters:
host- Product ads host URL
-
displayAdsHost
final OsmosSDK.Companion.Builder displayAdsHost(String host)
Sets the display ads host (optional).
- Parameters:
host- Display ads host URL
-
eventTrackingHost
final OsmosSDK.Companion.Builder eventTrackingHost(String host)
Sets the event tracking host (optional).
- Parameters:
host- Event tracking host URL
-
debug
final OsmosSDK.Companion.Builder debug(Boolean debug)
Enables or disables debug mode (optional).
- Parameters:
debug- True to enable debug logging, false otherwise
-
errorCallback
final OsmosSDK.Companion.Builder errorCallback(WeakReference<ErrorCallback> callback)
Sets the error callback for handling initialization errors (optional).
- Parameters:
callback- Callback to handle error scenarios
-
buildGlobalInstance
final Unit buildGlobalInstance()
Validates the configuration and initializes the SDK as singleton.
-
-
-
-