TerminalException

class TerminalException @JvmOverloads constructor(errorCode: TerminalException.TerminalErrorCode, errorMessage: String, cause: Throwable?, apiError: ApiError?) : Exception

A TerminalException represents an error thrown during SDK operations and will contain a TerminalErrorCode and an errorMessage to provide more specific details.

Use of this SDK is subject to the Stripe Terminal Terms: https://stripe.com/terminal/legal

Constructors

Link copied to clipboard
fun TerminalException(errorCode: TerminalException.TerminalErrorCode, errorMessage: String, cause: Throwable? = null, apiError: ApiError? = null)

Types

Link copied to clipboard
enum TerminalErrorCode : Enum<TerminalException.TerminalErrorCode>

A TerminalErrorCode represents the class of error

Functions

Link copied to clipboard
fun addSuppressed(p0: Throwable)
Link copied to clipboard
open fun fillInStackTrace(): Throwable
Link copied to clipboard
open fun getLocalizedMessage(): String
Link copied to clipboard
open fun getStackTrace(): Array<StackTraceElement>
Link copied to clipboard
fun getSuppressed(): Array<Throwable>
Link copied to clipboard
open fun initCause(p0: Throwable): Throwable
Link copied to clipboard
open fun printStackTrace()
open fun printStackTrace(p0: PrintStream)
open fun printStackTrace(p0: PrintWriter)
Link copied to clipboard
open fun setStackTrace(p0: Array<StackTraceElement>)

Properties

Link copied to clipboard
val apiError: ApiError? = null

If the errorCode is STRIPE_API_ERROR or DECLINED_BY_STRIPE_API, this field will return a representation of the error object, with additional details.

Link copied to clipboard
open val cause: Throwable?
Link copied to clipboard
val errorCode: TerminalException.TerminalErrorCode

The error code associated with this exception.

Link copied to clipboard
val errorMessage: String

The error message associated with this exception.

Link copied to clipboard
open val message: String?
Link copied to clipboard
val paymentIntent: PaymentIntent?

If the exception is related to a PaymentIntent, this will return one of three things: