io.paymenthighway.sdk.ui / SecurityCodeEditText

SecurityCodeEditText

class SecurityCodeEditText : EditText

Specialized text field for collecting security code.

Constructors

<init>

SecurityCodeEditText(context: Context?)
SecurityCodeEditText(context: Context?, attrs: AttributeSet?)
SecurityCodeEditText(context: Context?, attrs: AttributeSet?, defStyleAttr: Int)

TextInputEditText constructor

Properties

cardBrand

var cardBrand: () -> CardBrand?

Security code validation, format and hint depend of the card brand

Inherited Properties

editTextValidationListener

var editTextValidationListener: ValidationListener?

Listener for validation state change

errorText

var errorText: String?

Text message shown in case of error

format

var format: (String) -> String

Text formatter

hintText

var hintText: String?

Hint text

isValid

var isValid: Boolean

Return True if the field is valid

textLayout

var textLayout: TextInputLayout?

Parent TextInputLayout

validate

var validate: (String) -> Boolean

Text validation

Functions

onFocusChanged

fun onFocusChanged(focused: Boolean, direction: Int, previouslyFocusedRect: Rect?): Unit

The hint text can change depending of the card brand