Interface InAppMessageEventHandler
-
- All Implemented Interfaces:
public interface InAppMessageEventHandlerInterface for take actions on an InAppMessage presentation.
-
-
Method Summary
Modifier and Type Method Description abstract UnithandleJavascriptMessage(String handlerName, AdobeCallback<String> callback)Registers a {@link JavascriptInterface} for the provided handler name to the {@link WebView} associated with the InAppMessage presentation to handle Javascript messages. abstract UnitevaluateJavascript(String jsContent, AdobeCallback<String> callback)Evaluates the provided javascript content in the {@link WebView} maintained by the InAppMessage and passes the result to the provided callback. -
-
Method Detail
-
handleJavascriptMessage
abstract Unit handleJavascriptMessage(String handlerName, AdobeCallback<String> callback)
Registers a {@link JavascriptInterface} for the provided handler name to the {@link WebView} associated with the InAppMessage presentation to handle Javascript messages. When the registered handlers are executed via the HTML the result will be passed back to the associated callback.
- Parameters:
handlerName- the name of the handler to registercallback- the callback to be invoked with the result of the javascript execution
-
evaluateJavascript
abstract Unit evaluateJavascript(String jsContent, AdobeCallback<String> callback)
Evaluates the provided javascript content in the {@link WebView} maintained by the InAppMessage and passes the result to the provided callback.
- Parameters:
jsContent- the javascript content to be executedcallback- the callback to be invoked with the result of the javascript execution
-
-
-
-