Package org.aoju.bus.setting.metric
Class GroupMap
java.lang.Object
- All Implemented Interfaces:
Serializable,Cloneable,Map<String,,LinkedHashMap<String, String>> SequencedMap<String,LinkedHashMap<String, String>>
基于分组的Map
- Since:
- Java 17+
- Author:
- Kimi Liu
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K, V> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription清除指定分组下的所有键值对booleancontainsKey(String group, String key) 指定分组中是否包含指定keybooleancontainsValue(String group, String value) 指定分组中是否包含指定值指定分组下所有键值对get(CharSequence group, CharSequence key) 获取分组对应的值,如果分组不存在或者值不存在则返回nullbooleanisEmpty()是否为空,如果多个分组同时为空,也按照空处理boolean某个分组对应的键值对是否为空指定分组所有键的Set将键值对加入到对应分组中加入多个键值对到某个分组下从指定分组中删除指定值intsize()总的键值对数指定分组下所有值Methods inherited from class java.util.LinkedHashMap
clear, containsValue, entrySet, forEach, get, getOrDefault, keySet, newLinkedHashMap, putFirst, putLast, removeEldestEntry, replaceAll, reversed, sequencedEntrySet, sequencedKeySet, sequencedValues, valuesMethods inherited from class java.util.HashMap
clone, compute, computeIfAbsent, computeIfPresent, containsKey, merge, newHashMap, put, putAll, putIfAbsent, remove, remove, replace, replaceMethods inherited from class java.util.AbstractMap
equals, hashCode, toStringMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, containsKey, equals, hashCode, merge, put, putAll, putIfAbsent, remove, remove, replace, replaceMethods inherited from interface java.util.SequencedMap
firstEntry, lastEntry, pollFirstEntry, pollLastEntry
-
Constructor Details
-
GroupMap
public GroupMap()
-
-
Method Details
-
get
获取分组对应的值,如果分组不存在或者值不存在则返回null- Parameters:
group- 分组key- 键- Returns:
- 值, 如果分组不存在或者值不存在则返回null
-
size
-
put
-
putAll
-
remove
-
isEmpty
-
isEmpty
-
containsKey
-
containsValue
-
clear
-
keySet
-
values
-
entrySet
-