PMPpcRequestSenderImpl

class PMPpcRequestSenderImpl(val context: Context, val cfg: PartyConfig = PartyConfigProduction) : PMPpcRequestSender

Implementation for sending messages via CMD-interface

Samples

import android.content.Context
import com.sygic.profi.sdk.party.ppc.PMPpcRequestSenderImpl
import kotlin.random.Random
fun main() { 
   //sampleStart 
   object PPCSender {
    fun askForRoute(context: Context) {
        // feel free to setup own value of correlationId
        val ownCorrelationId = "ASK-ROUTE-${Random.nextInt()}"
        // Send request for sending polyline again
        PMPpcRequestSenderImpl(context).askForRoute(ownCorrelationId)
    }
} 
   //sampleEnd
}

Constructors

Link copied to clipboard
fun PMPpcRequestSenderImpl(context: Context, cfg: PartyConfig = PartyConfigProduction)

Functions

Link copied to clipboard
open fun askForRoute(correlationId: String)

PPC asks Navigation to send existing route via event.NaviStart or information, that there is no routing set-up.

Link copied to clipboard
open override fun broadcast(ppcRequest: PMPpcRequest)

Intent to start activity which will handle the command

Properties

Link copied to clipboard
Link copied to clipboard
val context: Context