DinersClub
DinersClub("diners", "Diners Club", R.drawable.stripe_ic_diners, 16, Pattern.compile("^(36|30|38|39)[0-9]*$"), mapOf(
1 to Pattern.compile("^3$")
), mapOf(
Pattern.compile("^(36)[0-9]*$") to 14
))
Content copied to clipboard
Diners Club
14-digits: BINs starting with 36 16-digits: BINs starting with 30, 38, 39
Functions
Link copied to clipboard
If the CardBrand has variants, and the cardNumber starts with one of the variant prefixes, return the length for that variant. Otherwise, return defaultMaxLength.
Link copied to clipboard
Checks to see whether the input number is of the correct length, given the assumed brand of the card. This function does not perform a Luhn check.
Link copied to clipboard