Details
-
Improvement
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
0.12.0
-
None
-
Patch Available
Description
One of these methods is not like the other (collections are pre-sized).
TUnion.java
private static Map deepCopyMap(Map<Object, Object> map) { Map copy = new HashMap(); for (Map.Entry<Object, Object> entry : map.entrySet()) { copy.put(deepCopyObject(entry.getKey()), deepCopyObject(entry.getValue())); } return copy; } private static Set deepCopySet(Set set) { Set copy = new HashSet(); for (Object o : set) { copy.add(deepCopyObject(o)); } return copy; } private static List deepCopyList(List list) { List copy = new ArrayList(list.size()); for (Object o : list) { copy.add(deepCopyObject(o)); } return copy; }
Attachments
Attachments
Issue Links
- links to