private static void initializeMap() { columnToKey.put(10, "term"); columnToKey.put(12, "chief"); columnToKey.put(17, "petitioner"); columnToKey.put(19, "respondent"); columnToKey.put(41, "issueArea"); columnToKey.put(42, "decisionDirection"); columnToKey.put(46, "lawType"); }
private static List<String> facetStringToListOfKeys(String facets) throws Exception { List<String> facetList = new ArrayList<String>(); String array[] = facets.split(","); for (int i = 0; i < array.length; i++) { int temp = Integer.parseInt(array[i]); String key = columnToKey.get(temp); if (key != null) { facetList.add(key); } } return facetList; }