List of utility methods to do Set Copy
void | copy(Set copy target.addAll(source); |
Set | copy(Set Copies the given Set into a new Set . final int size = data.size(); switch (size) { case 0: return Collections.emptySet(); case 1: return Collections.singleton(data.iterator().next()); default: return Collections.unmodifiableSet(new HashSet<T>(data)); ... |
Set | copyFeatureSet(Set copy Feature Set Set<String> res = new HashSet<>(); for (String s : o) { res.add(s); return res; |
void | copySet(Set copy Set for (Iterator<E> it = src.iterator(); it.hasNext();) {
dest.add(it.next());
|
Set | copyToSet(Iterable extends E> elements) copy To Set Set<E> set = new LinkedHashSet<E>(); addAll(set, elements); return set; |