Package com.batch.android.module
Class BatchModule
- java.lang.Object
-
- com.batch.android.module.BatchModule
-
- Direct Known Subclasses:
ActionModule,BatchModuleMaster,DisplayReceiptModule,EventDispatcherModule,LocalCampaignsModule,MessagingModule,OptOutModule,PushModule,TrackerModule,UserModule
public abstract class BatchModule extends java.lang.ObjectAbstract class of a Batch Module
-
-
Constructor Summary
Constructors Constructor Description BatchModule()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voidbatchContextBecameAvailable(android.content.Context applicationContext)Called by Batch as soon as a context is available in the runtimeManager For convenience, the application context is available as a parameter.voidbatchDidStart()Called by Batch right after batch start
NB : Same context and activity that in willStart but with the new stateState.READYsetvoidbatchDidStop()Called by Batch right after batch stop
NB : No context or activity are availablevoidbatchIsFinishing()Called by Batch before switching toState.FINISHING
NB : Context and activity are still available from the runtimeManagervoidbatchWillStart()Called by Batch before batch start
NB : Context & activity are already available from the runtimeManagervoidbatchWillStop()Called by Batch before switching toState.OFF
NB : Context is still available from runtimeManager (not activity)abstract java.lang.StringgetId()ID of the moduleabstract intgetState()Should return the state of the module (usually 0 for deactivated, 1 for activated)
-
-
-
Method Detail
-
getId
public abstract java.lang.String getId()
ID of the module- Returns:
-
getState
public abstract int getState()
Should return the state of the module (usually 0 for deactivated, 1 for activated)- Returns:
-
batchContextBecameAvailable
public void batchContextBecameAvailable(@NonNull android.content.Context applicationContext)Called by Batch as soon as a context is available in the runtimeManager For convenience, the application context is available as a parameter. LocalBroadcastManager is also up.
-
batchWillStart
public void batchWillStart()
Called by Batch before batch start
NB : Context & activity are already available from the runtimeManager
-
batchDidStart
public void batchDidStart()
Called by Batch right after batch start
NB : Same context and activity that in willStart but with the new stateState.READYset
-
batchIsFinishing
public void batchIsFinishing()
Called by Batch before switching toState.FINISHING
NB : Context and activity are still available from the runtimeManager
-
batchWillStop
public void batchWillStop()
Called by Batch before switching toState.OFF
NB : Context is still available from runtimeManager (not activity)
-
batchDidStop
public void batchDidStop()
Called by Batch right after batch stop
NB : No context or activity are available
-
-