IdCardKit { public static String getCheckCode18(int iSum) { String sCode = ""; switch (iSum % 11) { case 10: sCode = "2"; break; case 9: sCode = "3"; break; case 8: sCode = "4"; break; case 7: sCode = "5"; break; case 6: sCode = "6"; break; case 5: sCode = "7"; break; case 4: sCode = "8"; break; case 3: sCode = "9"; break; case 2: sCode = "x"; break; case 1: sCode = "0"; break; case 0: sCode = "1"; break; } return sCode; }  static String conver15CardTo18(String idCard); static boolean validateCard(String idCard); static boolean validateIdCard18(String idCard); static boolean validateIdCard15(String idCard); static String[] validateIdCard10(String idCard); static boolean validateTWCard(String idCard); static boolean validateHKCard(String idCard); static int[] converCharToInt(char[] ca); static int getPowerSum(int[] iArr); static String getCheckCode18(int iSum); static int getAgeByIdCard(String idCard); static String getBirthByIdCard(String idCard); static Short getYearByIdCard(String idCard); static Short getMonthByIdCard(String idCard); static Short getDateByIdCard(String idCard); static String getGenderByIdCard(String idCard); static String getProvinceByIdCard(String idCard); static final int CHINA_ID_MIN_LENGTH; static final int CHINA_ID_MAX_LENGTH; static final String cityCode; static final int power; static final String verifyCode; static final int MIN; static final Map<String, String> cityCodes; static final Map<String, Integer> twFirstCode; static final Map<String, Integer> hkFirstCode; }
@Test public void testGetCheckCode18() throws Exception { }