Package com.yubico.internal.util
Class CollectionUtil
- java.lang.Object
-
- com.yubico.internal.util.CollectionUtil
-
public class CollectionUtil extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description CollectionUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static <T> java.util.List<T>immutableList(java.util.List<T> l)Make an unmodifiable shallow copy of the argument.static <K,V>
java.util.Map<K,V>immutableMap(java.util.Map<K,V> m)Make an unmodifiable shallow copy of the argument.static <T> java.util.Set<T>immutableSet(java.util.Set<T> s)Make an unmodifiable shallow copy of the argument.static <T> java.util.Set<T>immutableSortedSet(java.util.SortedSet<T> s)Make an unmodifiable shallow copy of the argument.
-
-
-
Method Detail
-
immutableMap
public static <K,V> java.util.Map<K,V> immutableMap(java.util.Map<K,V> m)
Make an unmodifiable shallow copy of the argument.- Returns:
- A shallow copy of
mwhich cannot be modified
-
immutableList
public static <T> java.util.List<T> immutableList(java.util.List<T> l)
Make an unmodifiable shallow copy of the argument.- Returns:
- A shallow copy of
lwhich cannot be modified
-
immutableSet
public static <T> java.util.Set<T> immutableSet(java.util.Set<T> s)
Make an unmodifiable shallow copy of the argument.- Returns:
- A shallow copy of
swhich cannot be modified
-
immutableSortedSet
public static <T> java.util.Set<T> immutableSortedSet(java.util.SortedSet<T> s)
Make an unmodifiable shallow copy of the argument.- Returns:
- A shallow copy of
swhich cannot be modified
-
-