ValidationBuilder

A builder for creating PaymentCardNumberRules.

Constructors

Link copied to clipboard
constructor()

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard

Builds the validation rule.

Link copied to clipboard
fun setAlgorithm(algorithm: ChecksumAlgorithm, errorMsg: String = CheckSumValidator.DEFAULT_ERROR_MSG): PaymentCardNumberRule.ValidationBuilder

Sets the checksum algorithm for validation.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun setAllowableNumberLength(length: IntArray, errorMsg: String = LengthMatchValidator.DEFAULT_ERROR_MSG): PaymentCardNumberRule.ValidationBuilder

Sets the allowable lengths.

Link copied to clipboard

Sets whether to override the default validation rules.

Link copied to clipboard
fun setRegex(regex: String, errorMsg: String = RegexValidator.DEFAULT_ERROR_MSG): PaymentCardNumberRule.ValidationBuilder

Sets the regex for validation.