List of utility methods to do SortedSet Create
SortedSet | getSortedSet(int begin, int end) get Sorted Set SortedSet<Integer> set = new TreeSet<>(); for (int i = begin; i < end; i++) { set.add(i); return set; |
SortedSet | getSortedSet(String s) get Sorted Set SortedSet<String> sortedSet = new TreeSet<String>(); if (s == null || s.length() == 0) return sortedSet; String[] sa = s.split(" "); for (int i = 0; i < sa.length; i++) { sortedSet.add(sa[i]); return sortedSet; ... |