Class BaseDropInService
-
- All Implemented Interfaces:
-
android.content.ComponentCallbacks,android.content.ComponentCallbacks2,com.adyen.checkout.dropin.BaseDropInServiceContract,com.adyen.checkout.dropin.internal.service.BaseDropInServiceInterface,kotlinx.coroutines.CoroutineScope
public abstract class BaseDropInService extends Service implements CoroutineScope, BaseDropInServiceInterface, BaseDropInServiceContract
-
-
Field Summary
Fields Modifier and Type Field Description private final CoroutineContextcoroutineContext
-
Constructor Summary
Constructors Constructor Description BaseDropInService()
-
Method Summary
Modifier and Type Method Description final CoroutineContextgetCoroutineContext()IntegeronStartCommand(Intent intent, Integer flags, Integer startId)IBinderonBind(Intent intent)BooleanonUnbind(Intent intent)UnitonRebind(Intent intent)UnitonCreate()UnitonDestroy()final UnitsendResult(DropInServiceResult result)Allows sending the result of the /payments and /payments/details network calls. final UnitsendBalanceResult(BalanceDropInServiceResult result)Allows sending the result of the /paymentMethods/balance network call. final UnitsendOrderResult(OrderDropInServiceResult result)Allows sending the result of the /orders network call. final UnitsendRecurringResult(RecurringDropInServiceResult result)Allows sending the result of the DELETE /storedPaymentMethods network call. final UnitsendAddressLookupResult(AddressLookupDropInServiceResult result)Allows sending the result of Address Lookup operations. final UnitobserveResult(Function1<BaseDropInServiceResult, Unit> callback)final UnitrequestRemoveStoredPaymentMethod(StoredPaymentMethod storedPaymentMethod)final BundlegetAdditionalData()Gets the additional data that was set when starting Drop-in using DropInConfiguration.Builder. final UnitonRedirectCalled()final UnitonBinValueCalled(String binValue)final UnitonBinLookupCalled(List<BinLookupData> data)final UnitonAddressLookupQueryChangedCalled(String query)final BooleanonAddressLookupCompletionCalled(LookupAddress lookupAddress)-
Methods inherited from class com.adyen.checkout.dropin.internal.service.BaseDropInServiceInterface
requestBalanceCall, requestCancelOrder, requestDetailsCall, requestOrdersCall, requestPaymentsCall -
Methods inherited from class com.adyen.checkout.dropin.BaseDropInServiceContract
onAddressLookupCompletion, onAddressLookupQueryChanged, onBinLookup, onBinValue, onRedirect, onRemoveStoredPaymentMethod -
Methods inherited from class android.content.ContextWrapper
bindIsolatedService, bindService, bindService, bindService, bindService, bindServiceAsUser, bindServiceAsUser, checkCallingOrSelfPermission, checkCallingOrSelfUriPermission, checkCallingOrSelfUriPermissions, checkCallingPermission, checkCallingUriPermission, checkCallingUriPermissions, checkPermission, checkSelfPermission, checkUriPermission, checkUriPermission, checkUriPermissions, clearWallpaper, createAttributionContext, createConfigurationContext, createContext, createContextForSplit, createDeviceContext, createDeviceProtectedStorageContext, createDisplayContext, createPackageContext, createWindowContext, createWindowContext, databaseList, deleteDatabase, deleteFile, deleteSharedPreferences, enforceCallingOrSelfPermission, enforceCallingOrSelfUriPermission, enforceCallingPermission, enforceCallingUriPermission, enforcePermission, enforceUriPermission, enforceUriPermission, fileList, getApplicationContext, getApplicationInfo, getAssets, getAttributionSource, getAttributionTag, getBaseContext, getCacheDir, getClassLoader, getCodeCacheDir, getContentResolver, getDataDir, getDatabasePath, getDeviceId, getDir, getDisplay, getExternalCacheDir, getExternalCacheDirs, getExternalFilesDir, getExternalFilesDirs, getExternalMediaDirs, getFileStreamPath, getFilesDir, getMainExecutor, getMainLooper, getNoBackupFilesDir, getObbDir, getObbDirs, getOpPackageName, getPackageCodePath, getPackageManager, getPackageName, getPackageResourcePath, getParams, getResources, getSharedPreferences, getSystemService, getSystemServiceName, getTheme, getWallpaper, getWallpaperDesiredMinimumHeight, getWallpaperDesiredMinimumWidth, grantUriPermission, isDeviceProtectedStorage, isRestricted, isUiContext, moveDatabaseFrom, moveSharedPreferencesFrom, openFileInput, openFileOutput, openOrCreateDatabase, openOrCreateDatabase, peekWallpaper, registerComponentCallbacks, registerDeviceIdChangeListener, registerReceiver, registerReceiver, registerReceiver, registerReceiver, removeStickyBroadcast, removeStickyBroadcastAsUser, revokeSelfPermissionsOnKill, revokeUriPermission, revokeUriPermission, sendBroadcast, sendBroadcast, sendBroadcast, sendBroadcastAsUser, sendBroadcastAsUser, sendOrderedBroadcast, sendOrderedBroadcast, sendOrderedBroadcast, sendOrderedBroadcast, sendOrderedBroadcast, sendOrderedBroadcast, sendOrderedBroadcastAsUser, sendStickyBroadcast, sendStickyBroadcast, sendStickyBroadcastAsUser, sendStickyOrderedBroadcast, sendStickyOrderedBroadcastAsUser, setTheme, setWallpaper, setWallpaper, startActivities, startActivities, startActivity, startActivity, startForegroundService, startInstrumentation, startIntentSender, startIntentSender, startService, stopService, unbindService, unregisterComponentCallbacks, unregisterDeviceIdChangeListener, unregisterReceiver, updateServiceGroup -
Methods inherited from class android.content.Context
bindIsolatedService, getColor, getColorStateList, getDrawable, getString, getString, getSystemService, getText, obtainStyledAttributes, obtainStyledAttributes, obtainStyledAttributes, obtainStyledAttributes, revokeSelfPermissionOnKill, sendBroadcastWithMultiplePermissions -
Methods inherited from class android.app.Service
getApplication, getForegroundServiceType, onConfigurationChanged, onLowMemory, onStart, onTaskRemoved, onTimeout, onTrimMemory, startForeground, startForeground, stopForeground, stopForeground, stopSelf, stopSelf, stopSelfResult -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
getCoroutineContext
final CoroutineContext getCoroutineContext()
-
onStartCommand
Integer onStartCommand(Intent intent, Integer flags, Integer startId)
-
sendResult
final Unit sendResult(DropInServiceResult result)
Allows sending the result of the /payments and /payments/details network calls.
Call this method with a DropInServiceResult depending on the response of the corresponding network call.
Check the subclasses of DropInServiceResult for more information.
- Parameters:
result- the result of the network call.
-
sendBalanceResult
final Unit sendBalanceResult(BalanceDropInServiceResult result)
Allows sending the result of the /paymentMethods/balance network call.
Call this method with a BalanceDropInServiceResult depending on the response of the corresponding network call.
Check the subclasses of BalanceDropInServiceResult for more information.
- Parameters:
result- the result of the network request.
-
sendOrderResult
final Unit sendOrderResult(OrderDropInServiceResult result)
Allows sending the result of the /orders network call.
Call this method with a OrderDropInServiceResult depending on the response of the corresponding network call.
Check the subclasses of OrderDropInServiceResult for more information.
- Parameters:
result- the result of the network request.
-
sendRecurringResult
final Unit sendRecurringResult(RecurringDropInServiceResult result)
Allows sending the result of the DELETE /storedPaymentMethods network call.
Call this method with a RecurringDropInServiceResult depending on the response of the corresponding network call.
Check the subclasses of RecurringDropInServiceResult for more information.
- Parameters:
result- the result of the network call.
-
sendAddressLookupResult
final Unit sendAddressLookupResult(AddressLookupDropInServiceResult result)
Allows sending the result of Address Lookup operations.
Call this method with a AddressLookupDropInServiceResult depending on the performed address lookup action.
Check the subclasses of AddressLookupDropInServiceResult for more information.
- Parameters:
result- the result of the action.
-
observeResult
final Unit observeResult(Function1<BaseDropInServiceResult, Unit> callback)
-
requestRemoveStoredPaymentMethod
final Unit requestRemoveStoredPaymentMethod(StoredPaymentMethod storedPaymentMethod)
-
getAdditionalData
final Bundle getAdditionalData()
Gets the additional data that was set when starting Drop-in using DropInConfiguration.Builder.setAdditionalDataForDropInService or null if nothing was set.
-
onRedirectCalled
final Unit onRedirectCalled()
-
onBinValueCalled
final Unit onBinValueCalled(String binValue)
-
onBinLookupCalled
final Unit onBinLookupCalled(List<BinLookupData> data)
-
onAddressLookupQueryChangedCalled
final Unit onAddressLookupQueryChangedCalled(String query)
-
onAddressLookupCompletionCalled
final Boolean onAddressLookupCompletionCalled(LookupAddress lookupAddress)
-
-
-
-