Package com.inmobi.signals.synapse
Object SynapseManager
-
- All Implemented Interfaces:
public class SynapseManagerMain orchestrator for Project Synapse signal collection.
Initialization is driven by SDK init via initialize. Collection and push are async and do not block SDK startup or ad-load flows.
Manifest-controlled lane: a SynapseTriggerQueue serialises manifest trigger cycles. SDK_INIT is enqueued from initialize and FOREGROUND is enqueued from onAppForegrounded. Other runtime triggers are enqueued through onRuntimeTrigger.
-
-
Field Summary
Fields Modifier and Type Field Description public final static SynapseManagerINSTANCE
-
Method Summary
Modifier and Type Method Description final Unitinitialize(Context appContext)Called during SDK initialization. final UnitonAppForegrounded()Marks the app foregrounded and enqueues FOREGROUND for the manifest-controlled lane. final UnitonAppBackgrounded()Defers new manifest collection cycles until the app returns to the foreground. final UnitsetScopeForTesting(CoroutineScope scope)final UnitsetClockForTesting(Clock testClock)final UnitsetPushForTesting(SuspendFunction1<JSONObject, SynapseSignalsPushResult> push)final UnitsetSignalsConfigForTesting(SignalsConfig config)final UnitresetForTesting()-
-
Method Detail
-
initialize
final Unit initialize(Context appContext)
Called during SDK initialization. Checks global Synapse enablement, enqueues SDK_INIT, then fetches the manifest and initialises the trigger processor for the session.
-
onAppForegrounded
final Unit onAppForegrounded()
Marks the app foregrounded and enqueues FOREGROUND for the manifest-controlled lane.
-
onAppBackgrounded
final Unit onAppBackgrounded()
Defers new manifest collection cycles until the app returns to the foreground.
-
setScopeForTesting
final Unit setScopeForTesting(CoroutineScope scope)
-
setClockForTesting
final Unit setClockForTesting(Clock testClock)
-
setPushForTesting
final Unit setPushForTesting(SuspendFunction1<JSONObject, SynapseSignalsPushResult> push)
-
setSignalsConfigForTesting
final Unit setSignalsConfigForTesting(SignalsConfig config)
-
resetForTesting
final Unit resetForTesting()
-
-
-
-