All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.sri.ai.util.collect.StackedMap Maven / Gradle / Ivy

There is a newer version: 1.3.3
Show newest version
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