com.sri.ai.util.collect.StackedMap Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of aic-util Show documentation
Show all versions of aic-util Show documentation
SRI International's AIC Utility Library (for Java 1.6+)
package com.sri.ai.util.collect;
import java.util.Map;
/**
* A Map based on another Map (the base), and storing only the differences between itself and the base.
* When an entry is added to this map, it will mask another one in the base map.
*
* This is useful when we want a "copy" of a map to which we will add entries, without actually having to copy all original entries.
*
* Beware: changes to entries still residing in the base map are reflected in it!
*
* IMPORTANT: as of October 2015, implementation {@link AbstractStackedMap} does not reflect changes made through
* {@link Map#entrySet()}, {@link Map#keySet()}, and {@link Map#values()}.
*/
public interface StackedMap extends Map {
public abstract Map getTop();
public abstract void setTop(Map top);
public abstract Map getBase();
public abstract void setBase(Map base);
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy