PMPpcEventReceiver
Simple implementation of BroadCastReceiver for PPC Events
Integrator has to :
- register this class in android
- define action filter
Samples
import android.content.Context
import android.content.IntentFilter
import com.sygic.profi.model.pm.ppc.PMPpcEvent
import com.sygic.profi.sdk.ifc.PMConstants
import com.sygic.profi.sdk.ifc.ppc.PMPpcEventIfc
import com.sygic.profi.sdk.party.ppc.PMPpcEventReceiver
fun main() {
//sampleStart
class PPCReceiver: PMPpcEventIfc {
private val receiver = PMPpcEventReceiver(this)
fun register(context: Context) {
context.registerReceiver(receiver, IntentFilter(PMConstants.FILTER_PPC))
}
fun unregister(context: Context) {
context.unregisterReceiver(receiver)
}
override fun broadcast(ppc: PMPpcEvent) {
assert(ppc.correlationId != null)
TODO("Do something useful with PMPpcEvent")
}
}
//sampleEnd
}Constructors
Functions
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard