code: public static String getIdentifierByCodePageName(String cpName) {
          if (cpName != null) {
              for (Entry<String, String> codePage : codePages.entrySet()) {
                  if (codePage.getValue().toLowerCase().equals(cpName.toLowerCase())) {
                      return codePage.getKey();
                  }
              }
          }
          //Default UTF-8
          return "65001";
      }
docs: Get the CodePage code from encoding value
  
  @param cpName the codepage name
  @return String the identifier