Checks to see if the cc number is a valid EnRoute number @param cc - a string representing a credit card number; Sample number: 201400000000009(15 digits) @return true, if the credit card number is a valid enRoute card number, false, otherwise
(String cc)
| 976 | * @return true, if the credit card number is a valid enRoute card number, false, otherwise |
| 977 | */ |
| 978 | public static boolean isEnRoute(String cc) { |
| 979 | String first4digs = cc.substring(0, 4); |
| 980 | |
| 981 | if ((cc.length() == 15) && (first4digs.equals("2014") || first4digs.equals("2149"))) |
| 982 | return isCreditCard(cc); |
| 983 | return false; |
| 984 | } |
| 985 | |
| 986 | /** Checks to see if the cc number is a valid JCB number |
| 987 | * @param cc - a string representing a credit card number; Sample number: 3088000000000009(16 digits) |
no test coverage detected