public class PushWrap extends PushListenerService
{
private BA ba = null;
private String eventName;
public void Initialize(BA ba, String eventName)
{
this.ba = ba;
this.eventName = eventName;
Push.initialize(ba.activity, true);
}
@Override
@BA.Hide
public void onMessageReceived(JSONObject message)
{
// Your code
String messageString; //convert message to messageString, somehow
ba.raiseEvent2(null, true, eventName.toLowerCase() + "_messagereceived", false, messageString); //This raises an event
}
}