public final class SubKeyMap<V> extends AbstractMap<String,V>
Note that there is a potential design flaw; if you create a SubKeyMap for "mypackage.foo" and for "mypackage.foo.bar", all the keys in the latter will actually show up in the former (prefixed by ".bar"). This "flaw" is actually relied on by PageFlowScopeMap (since it provides a handy way to clear out all descendents), so don't "fix" it!
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
Constructor and Description |
---|
SubKeyMap(Map<String,Object> base,
String prefix) |
Modifier and Type | Method and Description |
---|---|
boolean |
containsKey(Object key) |
Set<Map.Entry<String,V>> |
entrySet() |
V |
get(Object key) |
boolean |
isEmpty() |
V |
put(String key,
V value) |
V |
remove(Object key) |
clear, clone, containsValue, equals, hashCode, keySet, putAll, size, toString, values
finalize, getClass, notify, notifyAll, wait, wait, wait
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
public boolean isEmpty()
public boolean containsKey(Object key)
containsKey
in interface Map<String,V>
containsKey
in class AbstractMap<String,V>
Copyright © 2021 The Apache Software Foundation. All rights reserved.