KlarnaComponent
to manage payments for Klarna.
fun provideKlarnaComponent(primerSessionIntent: PrimerSessionIntent): KlarnaComponent
Hide Parameters
KlarnaComponent
.
Hide KlarnaComponent
submit
function in order to process collected data and move component to next state.Show sealed interface KlarnaPaymentCollectableData
Hide Properties
Show Properties
Show Properties
KlarnaPaymentStep
is a class holding different output data for specific steps. Whenever
start or submit methods are
called, componentStep
will trigger the next step in case the call to the mentioned method was successful.
Show sealed interface KlarnaPaymentStep
Hide Properties
Show Properties
Show Properties
Hide Properties
Hide Properties
PrimerValidationStatus
interface encompasses a range of validation statuses.Show sealed interface PrimerValidationStatus
Hide Properties
Hide Properties
Hide Properties
PrimerValidationError
objects that represent data validation errors emitted by this component.Hide Properties
PrimerError
that occurred during validation.Show PrimerValidationError
class CheckoutActivity : AppCompatActivity() {
// 👇 Add this
private val klarnaComponent by lazy {
PrimerHeadlessUniversalCheckoutKlarnaManager(viewModelStoreOwner = this)
.provideKlarnaComponent(primerSessionIntent = PrimerSessionIntent.CHECKOUT)
}
}