List of utility methods to do Array to Set Convert
Set | asSet(T... vals) as Set HashSet<T> result = new HashSet<T>(); for (T i : vals) result.add(i); return result; |
Set | setOf(final T... items) set Of return Collections.unmodifiableSet(new HashSet<T>(Arrays .asList(items))); |