GooglePayLauncher

Responsible for launching the Google Pay payment sheet

Constructors

Link copied to clipboard
constructor(fragment: Fragment, callback: GooglePayLauncherCallback)

Used to launch the Google Pay payment sheet from within an Android Fragment. This class must be instantiated before the Fragment is created.

constructor(activity: ComponentActivity, callback: GooglePayLauncherCallback)

Used to launch the Google Pay payment sheet from within an Android Activity. This class must be instantiated before the Activity is created.

constructor(registry: ActivityResultRegistry, lifecycleOwner: LifecycleOwner, context: Context, callback: GooglePayLauncherCallback)

Used to launch the Google Pay payment sheet from a composable, or anywhere else a Fragment or ComponentActivity reference is not available. This class must be instantiated before the lifecycleOwner reaches the CREATED state.

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard

Launches the Google Pay payment sheet. This method cannot be called until the lifecycle of the Fragment or Activity used to instantiate your GooglePayLauncher has reached the CREATED state.