code: public static void main(String[] args) throws FileNotFoundException, IOException {
          InputStream codeStream = FeatureCodeBuilder.class.getClassLoader().getResourceAsStream("featureCodes_en.txt");
          BufferedReader in = new BufferedReader(new InputStreamReader(codeStream, Charset.forName("UTF-8")));
          // generate dummy feature code for top-level territories
          Set<Code> featureCodes = new TreeSet<Code>();
          featureCodes.add(new Code("TERRI", "A", "independent territory", "a territory that acts as an independent political entity",
                  "manually added to identify territories that can contain other administrative divisions"));
          String line;
          while ((line = in.readLine()) != null) {
              String[] tokens = line.split("\t");
              if (!tokens[0].equals("null")) {
                  String[] codes = tokens[0].split("\\.");
                  featureCodes.add(new Code(codes[1], codes[0], tokens[1], tokens.length == 3 ? tokens[2] : ""));
              }
          }
          in.close();
          for (Code code : featureCodes) {
              System.out.println(code);
          }
          System.out.println("// manually added for locations not assigned to a feature code");
          System.out.println("NULL(FeatureClass.NULL, \"not available\", \"\", false);");
      }
docs: Reads-in featureCodes_en.txt file, spits-out
  {@link FeatureClass} enum definitions.
  @param args the command line arguments
  
  @throws FileNotFoundException if featureCodes_en.txt is not found on the classpath
  @throws IOException if an error occurs reading the featureCodes file