本文整理了Java中brooklyn.util.collections.MutableMap.remove()
方法的一些代码示例,展示了MutableMap.remove()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。MutableMap.remove()
方法的具体详情如下:
包路径:brooklyn.util.collections.MutableMap
类名称:MutableMap
方法名:remove
暂无
代码示例来源:origin: io.brooklyn/brooklyn-utils-common
public Builder<K, V> removeAll(K... keys) {
for (K key : keys) {
result.remove(key);
}
return this;
}
代码示例来源:origin: io.brooklyn/brooklyn-utils-common
public Builder<K, V> removeAll(Iterable<? extends K> keys) {
for (K key : keys) {
result.remove(key);
}
return this;
}
代码示例来源:origin: io.brooklyn/brooklyn-utils-common
public Builder<K, V> remove(K key) {
result.remove(key);
return this;
}
代码示例来源:origin: io.brooklyn/brooklyn-utils-common
/** moves the value stored under oldKey to newKey, if there was such a value */
public Builder<K, V> renameKey(K oldKey, K newKey) {
if (result.containsKey(oldKey)) {
V oldValue = result.remove(oldKey);
result.put(newKey, oldValue);
}
return this;
}
代码示例来源:origin: io.brooklyn/brooklyn-core
public ProcessTool(Map<String,?> flags) {
super(getOptionalVal(flags, PROP_LOCAL_TEMP_DIR));
if (flags!=null) {
MutableMap<String, Object> flags2 = MutableMap.copyOf(flags);
// TODO should remember other flags here? (e.g. NO_EXTRA_OUTPUT, RUN_AS_ROOT, etc)
flags2.remove(PROP_LOCAL_TEMP_DIR.getName());
if (!flags2.isEmpty())
LOG.warn(""+this+" ignoring unsupported constructor flags: "+flags);
}
}
内容来源于网络,如有侵权,请联系作者删除!