Package com.github.toolarium.common.util
Class MapUtil
- java.lang.Object
-
- com.github.toolarium.common.util.MapUtil
-
public final class MapUtil extends java.lang.ObjectMap utility.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description <K,V>
java.util.Map<K,V>add(java.util.Map<K,V> map, java.util.Map<K,V> mapToAdd)Add a mapstatic MapUtilgetInstance()Get the instance<K,V>
java.util.Map<K,V>newMap()Create a new map<K,V>
java.util.Map<K,V>newMap(boolean sorted)Create a new map
-
-
-
Method Detail
-
getInstance
public static MapUtil getInstance()
Get the instance- Returns:
- the instance
-
newMap
public <K,V> java.util.Map<K,V> newMap()
Create a new map- Type Parameters:
K- the keyV- the value- Returns:
- the created map
-
newMap
public <K,V> java.util.Map<K,V> newMap(boolean sorted)
Create a new map- Type Parameters:
K- the keyV- the value- Parameters:
sorted- true if it is a sorted map- Returns:
- the created map
-
add
public <K,V> java.util.Map<K,V> add(java.util.Map<K,V> map, java.util.Map<K,V> mapToAdd)Add a map- Type Parameters:
K- the keyV- the value- Parameters:
map- the map to extendmapToAdd- the added map- Returns:
- the extended map
-
-