|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.rice.cs.plt.collect.AbstractKeyBasedMap<K,V>
edu.rice.cs.plt.collect.MappedMap<K,X,V>
public class MappedMap<K,X,V>
A map whose value set is translated by a mapping lambda.
MappedIterable,
ComposedMap,
Serialized Form| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class edu.rice.cs.plt.collect.AbstractKeyBasedMap |
|---|
AbstractKeyBasedMap.EntrySet |
| Nested classes/interfaces inherited from interface java.util.Map |
|---|
Map.Entry<K,V> |
| Constructor Summary | |
|---|---|
MappedMap(Map<K,? extends X> map,
Lambda<? super X,? extends V> lambda)
|
|
| Method Summary | |
|---|---|
void |
clear()
Throws an UnsupportedOperationException. |
int |
compositeHeight()
Get the maximum path length from this node to a leaf. |
int |
compositeSize()
Get the number of nodes in the tree rooted at this node. |
boolean |
containsKey(Object o)
Returns keySet().contains(key). |
V |
get(Object key)
|
boolean |
isEmpty()
Returns keySet().isEmpty(). |
PredicateSet<K> |
keySet()
|
V |
remove(Object key)
Throws an UnsupportedOperationException. |
int |
size()
Returns keySet().size(). |
Collection<V> |
values()
Return a collection backed by IterUtil.map(keySet(), this). |
| Methods inherited from class edu.rice.cs.plt.collect.AbstractKeyBasedMap |
|---|
containsValue, entrySet, equals, hashCode, mapEntryForKey, put, putAll, toString, value |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public MappedMap(Map<K,? extends X> map,
Lambda<? super X,? extends V> lambda)
| Method Detail |
|---|
public int compositeHeight()
Composite
compositeHeight in interface Compositepublic int compositeSize()
Composite
compositeSize in interface Compositepublic V get(Object key)
get in interface Map<K,V>get in class AbstractKeyBasedMap<K,V>public PredicateSet<K> keySet()
keySet in interface LambdaMap<K,V>keySet in interface Map<K,V>keySet in class AbstractKeyBasedMap<K,V>public V remove(Object key)
AbstractKeyBasedMapUnsupportedOperationException.
remove in interface Map<K,V>remove in class AbstractKeyBasedMap<K,V>public void clear()
AbstractKeyBasedMapUnsupportedOperationException.
clear in interface Map<K,V>clear in class AbstractKeyBasedMap<K,V>public int size()
AbstractKeyBasedMapkeySet().size().
size in interface Map<K,V>size in class AbstractKeyBasedMap<K,V>public boolean isEmpty()
AbstractKeyBasedMapkeySet().isEmpty().
isEmpty in interface Map<K,V>isEmpty in class AbstractKeyBasedMap<K,V>public boolean containsKey(Object o)
AbstractKeyBasedMapkeySet().contains(key).
containsKey in interface Map<K,V>containsKey in class AbstractKeyBasedMap<K,V>public Collection<V> values()
AbstractKeyBasedMapIterUtil.map(keySet(), this).
values in interface Map<K,V>values in class AbstractKeyBasedMap<K,V>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||