public interface

CheckoutExtension

com.usebutton.sdk.checkout.CheckoutExtension

Class Overview

This interface allows you to create a Checkout extension which allow dynamic customization of the checkout experience.

Summary

Public Methods
abstract void onClosed()
Called when the checkout flow is closed.
abstract void onInitialized(CheckoutInterface checkout)
Called during the initialization of the Checkout experience
abstract void onNavigate(String uri, CheckoutInterface checkout)
Called during navigation events in the checkout experience
abstract void onProductNavigate(Product product, Commission commission, CheckoutInterface checkout)
Called when the checkout flow navigates to a product.
abstract void onPurchase(CheckoutInterface checkout)
Called when a purchase is completed Note: This is not guaranteed to be called for every purchase as not all merchants are enabled for this feature

Public Methods

public abstract void onClosed ()

Called when the checkout flow is closed. This does not mean a purchase was completed.

public abstract void onInitialized (CheckoutInterface checkout)

Called during the initialization of the Checkout experience

Parameters
checkout An interface which allows you to customize the experience.

public abstract void onNavigate (String uri, CheckoutInterface checkout)

Called during navigation events in the checkout experience

Parameters
uri The uri the of the event. This can contain a web link or and Android URI
checkout The interface to the checkout object.

public abstract void onProductNavigate (Product product, Commission commission, CheckoutInterface checkout)

Called when the checkout flow navigates to a product. Note: This feature is supported by a subset of Merchants that is constantly growing. New Merchants may begin supporting this method at any time.

Parameters
product An object representing the product.
commission An object representing commission availability
checkout The interface to the checkout object.

public abstract void onPurchase (CheckoutInterface checkout)

Called when a purchase is completed Note: This is not guaranteed to be called for every purchase as not all merchants are enabled for this feature

Parameters
checkout The interface to the checkout object.