create Payment Method
open override fun createPaymentMethod(context: Context, params: IPaymentMethodParams?, callback: ApiResultCallback<IPaymentMethod?>)
Creates an IPaymentMethod instance with the provided parameters and returns it via callback.
Important:
This version of the method is provided mainly as convenience for Java developers. Kotlin developers should generally use the suspend version instead
Parameters
context
Activity or Application context
params
The parameters used to create the payment method
callback
The callback used to return the result.
Note: This callback returns on a background thread
open suspend override fun createPaymentMethod(context: Context, params: IPaymentMethodParams?): IPaymentMethod
Creates an IPaymentMethod instance with the provided parameters
Return
An IPaymentMethod instance, which can then be used to submit a basket to Olo's Ordering API
Parameters
context
Activity or Application context
params
The parameters used to create the payment method