android-components / mozilla.components.support.utils / asForegroundServicePendingIntent

asForegroundServicePendingIntent

@JvmName("createForegroundServicePendingIntent") fun <ERROR CLASS>.asForegroundServicePendingIntent(context: <ERROR CLASS>, requestCode: Int): <ERROR CLASS> (source)

Create a PendingIntent instance to run a certain service described with the Intent.

This method will allow you to launch a service that will be able to overpass background service limitations introduced in Android Oreo.

Parameters

context - an Intent to start a service.