AppKit

object AppKit : CloudSDKKoinComponent

Functions

closeAppActivity
Link copied to clipboard
fun closeAppActivity()

Closes (finishes) the AppActivity.

closeApps
Link copied to clipboard
fun closeApps(buttonContainer: ConstraintLayout)

Closes (removes) all AppDrawers in the buttonContainer parent layout.

fetchAppsByUrl
Link copied to clipboard
fun fetchAppsByUrl(url: String, vararg references: String, completion: (Completion<List<App>>) -> Unit)

Fetches the app with the given url and references (e.g. referenced gas station UUIDs).

fetchUrlByAppId
Link copied to clipboard
fun fetchUrlByAppId(appId: String, completion: (Completion<String?>) -> Unit)

Fetches the app's URL for the given appId (not gas station ID).

getKoin
Link copied to clipboard
open override fun getKoin(): Koin
openAppActivity
Link copied to clipboard
fun openAppActivity(context: Context, app: App, enableBackToFinish: Boolean = false, callback: AppCallbackImpl = defaultAppCallback)

Starts an AppActivity and loads the URL of the app in the cloud.pace.sdk.appkit.app.webview.AppWebView.

fun openAppActivity(context: Context, url: String, enableBackToFinish: Boolean = false, callback: AppCallbackImpl = defaultAppCallback)

Starts an AppActivity and loads the url of the app in the cloud.pace.sdk.appkit.app.webview.AppWebView.

openApps
Link copied to clipboard
fun openApps(context: Context, apps: List<App>, buttonContainer: ConstraintLayout, theme: Theme = Theme.LIGHT, bottomMargin: Float = 16f, callback: AppCallbackImpl = defaultAppCallback)

Adds an AppDrawer to the parent view buttonContainer for each app in apps list. Clicking on the AppDrawer opens the AppActivity and shows the App.

openDashboard
Link copied to clipboard
fun openDashboard(context: Context, enableBackToFinish: Boolean = true, callback: AppCallbackImpl = defaultAppCallback)

Starts an AppActivity and loads the Connected Fueling dashboard in the cloud.pace.sdk.appkit.app.webview.AppWebView.

openFuelingApp
Link copied to clipboard
fun openFuelingApp(context: Context, id: String? = null, enableBackToFinish: Boolean = true, callback: AppCallbackImpl = defaultAppCallback)

Starts an AppActivity and loads Fueling App in the cloud.pace.sdk.appkit.app.webview.AppWebView.

openPaceID
Link copied to clipboard
fun openPaceID(context: Context, enableBackToFinish: Boolean = true, callback: AppCallbackImpl = defaultAppCallback)
openPaymentApp
Link copied to clipboard
fun openPaymentApp(context: Context, enableBackToFinish: Boolean = true, callback: AppCallbackImpl = defaultAppCallback)

Starts an AppActivity and loads the Payment App in the cloud.pace.sdk.appkit.app.webview.AppWebView.

openTransactions
Link copied to clipboard
fun openTransactions(context: Context, enableBackToFinish: Boolean = true, callback: AppCallbackImpl = defaultAppCallback)

Starts an AppActivity and loads Transactions in the cloud.pace.sdk.appkit.app.webview.AppWebView.

requestApps
Link copied to clipboard
fun requestApps(completion: (Completion<List<App>>) -> Unit)

Returns a list of all apps.

requestLocalApps
Link copied to clipboard
fun requestLocalApps(completion: (Completion<List<App>>) -> Unit)

Checks for local based apps at the current location.

setCarData
Link copied to clipboard
fun setCarData(car: Car)

Sets car related data which could be needed by an App.

Properties

locationAccuracy
Link copied to clipboard
var locationAccuracy: Int? = null

Specifies the minimum location accuracy in meters to request location based apps.

theme
Link copied to clipboard
var theme: Theme

Specifies whether the light or dark theme should be used for the apps.