-
public class ActionModule extends BatchModule
Batch's Action Module.
-
-
Field Summary
Fields Modifier and Type Field Description public final static StringTAGpublic final static StringRESERVED_ACTION_IDENTIFIER_PREFIXprivate BatchDeeplinkInterceptordeeplinkInterceptor
-
Constructor Summary
Constructors Constructor Description ActionModule()
-
Method Summary
Modifier and Type Method Description BatchDeeplinkInterceptorgetDeeplinkInterceptor()Set the developer registered deeplink interceptor voidsetDeeplinkInterceptor(@Nullable() BatchDeeplinkInterceptor interceptor)Get the developer registered deeplink interceptor voidregisterAction(@NonNull() UserAction userAction)See register voidunregisterAction(@NonNull() String identifier)See unregister voidaddDrawableAlias(@NonNull() String alias, @DrawableRes() int drawableResID)See addDrawableAlias intgetAliasedDrawableID(@NonNull() String alias)booleanperformUserAction(@Nullable() Context context, @NonNull() String identifier, @Nullable() JSONObject args)Perform the specified action. booleanperformAction(@Nullable() Context context, @NonNull() String identifier, @NonNull() JSONObject args, @Nullable() UserActionSource source)Perform the specified action. intgetDrawableIdForNameOrAlias(@NonNull() Context context, @Nullable() String drawableName)StringgetId()ID of the module intgetState()Should return the state of the module (usually 0 for deactivated, 1 for activated) -
Methods inherited from class com.batch.android.module.BatchModule
batchContextBecameAvailable, batchDidStart, batchDidStop, batchIsFinishing, batchWillStart, batchWillStop -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
getDeeplinkInterceptor
@Nullable() BatchDeeplinkInterceptor getDeeplinkInterceptor()
Set the developer registered deeplink interceptor
-
setDeeplinkInterceptor
void setDeeplinkInterceptor(@Nullable() BatchDeeplinkInterceptor interceptor)
Get the developer registered deeplink interceptor
-
registerAction
void registerAction(@NonNull() UserAction userAction)
See register
-
unregisterAction
void unregisterAction(@NonNull() String identifier)
See unregister
-
addDrawableAlias
void addDrawableAlias(@NonNull() String alias, @DrawableRes() int drawableResID)
See addDrawableAlias
-
getAliasedDrawableID
@DrawableRes() int getAliasedDrawableID(@NonNull() String alias)
-
performUserAction
boolean performUserAction(@Nullable() Context context, @NonNull() String identifier, @Nullable() JSONObject args)
Perform the specified action.Meant for the public SDK
- Parameters:
context- Context, if anyidentifier- Action identifierargs- Action arguments in JSON form
-
performAction
boolean performAction(@Nullable() Context context, @NonNull() String identifier, @NonNull() JSONObject args, @Nullable() UserActionSource source)
Perform the specified action.Meant for the private SDK
- Parameters:
context- Context, if anyidentifier- Action identifierargs- Action arguments in JSON formsource- The action source
-
getDrawableIdForNameOrAlias
int getDrawableIdForNameOrAlias(@NonNull() Context context, @Nullable() String drawableName)
-
getState
int getState()
Should return the state of the module (usually 0 for deactivated, 1 for activated)
-
-
-
-