how to send data or message from java application / plugin to javascript with cordova / phonegap
问题 I think I'm missing something here. I'm used to sending data from javascript to java and back with calls to execute and back with the callbackContext methods. But if at some points, lets say I have a running thread that needs to send data to the javascript at regular intervals, how should I do that then ? (This assumes that this task is running and has not been triggered by a javascript action, thus no callbackContext is available) 回答1: You can always execute javascript from java doing this: