|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface MultiMapDiff
A MultiMap that is represented as a set of changes to some underlying MultiMap. The changes are additions and removals on the sets of objects associated with various keys. When using a MultiMapDiff, we do not need to copy any information for keys whose associated sets do not change. And for a keys whose set does change, we still do not need to copy all the objects that are in that set in both the underlying world and the MultiMapDiff.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface common.MultiMap |
---|
MultiMap.EmptyMultiMap |
Nested classes/interfaces inherited from interface java.util.Map |
---|
java.util.Map.Entry<K,V> |
Field Summary |
---|
Fields inherited from interface common.MultiMap |
---|
EMPTY_MULTI_MAP |
Method Summary | |
---|---|
void |
changeUnderlying()
Changes the underlying multi-map to equal this multi-map. |
void |
clearChanges()
Resets this multi-map to be equal to the underlying multi-map. |
java.util.Set |
getAddedValues(java.lang.Object key)
Returns the set of values that are associated with the given key in this multi-map and not in the underlying multi-map. |
java.util.Set |
getChangedKeys()
Returns the set of keys whose associated value sets are different in this multi-map and the underlying multi-map. |
java.util.Set |
getRemovedValues(java.lang.Object key)
Returns the set of values that are associated with the given key in the underlying multi-map but not in this multi-map. |
Methods inherited from interface common.MultiMap |
---|
add, addAll, get, put, remove, removeAll |
Methods inherited from interface java.util.Map |
---|
clear, containsKey, containsValue, entrySet, equals, hashCode, isEmpty, keySet, putAll, remove, size, values |
Method Detail |
---|
java.util.Set getChangedKeys()
The returned set may or may not be kept up to date as changes are made to this MultiMapDiff.
java.util.Set getAddedValues(java.lang.Object key)
The returned set may or may not be kept up to date as changes are made to this MultiMapDiff.
java.util.Set getRemovedValues(java.lang.Object key)
The returned set may or may not be kept up to date as changes are made to this MultiMapDiff.
void changeUnderlying()
void clearChanges()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |