|
Rice Pastry API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object rice.p2p.util.ReverseTreeMap
public class ReverseTreeMap
Field Summary | |
---|---|
protected java.util.SortedMap |
normal
The internal normal map |
protected java.util.SortedMap |
nulls
The internal list of keys with null as a mapping |
protected java.util.SortedMap |
reverse
The internal value -> list of keys map |
Constructor Summary | |
---|---|
|
ReverseTreeMap()
Constructor |
protected |
ReverseTreeMap(java.util.SortedMap normal,
java.util.SortedMap reverse,
java.util.SortedMap nulls)
Constructor |
Method Summary | |
---|---|
boolean |
containsKey(java.lang.Object key)
Returns whether or not we contain the key |
protected java.util.SortedMap |
convert(java.util.SortedMap map)
Internal method which converts a sortedmap to an iterator |
java.lang.Object |
get(java.lang.Object key)
Returns the value associated with the given key |
java.util.SortedMap |
keyHeadMap(java.lang.Object value)
Method which returns a *cloned* head map, or all of the values up to the specified value |
java.util.SortedMap |
keyMap()
Method which returns the key map |
java.util.Set |
keySet()
Return the set of keys |
java.util.SortedMap |
keySubMap(java.lang.Object start,
java.lang.Object end)
Method which returns a *cloned* sub map, or all of the values between the specified values |
java.util.SortedMap |
keyTailMap(java.lang.Object value)
Method which returns a *cloned* tail map, or all of the values after a the specified value |
void |
put(java.lang.Object key,
java.lang.Object value)
Method which caputures the insert and adds it to the reverse map |
void |
remove(java.lang.Object key)
Removes any and all mappings with the given key |
int |
size()
returns the size |
java.util.SortedMap |
valueHeadMap(java.lang.Object value)
Method which returns a headset of the values, or all the keys with values up to the specified value |
java.util.SortedMap |
valueNullMap()
Method which returns all of the keys which have null values |
java.util.SortedMap |
valueSubMap(java.lang.Object start,
java.lang.Object end)
Method which returns a headset of the values, or all the keys with values up to the specified value |
java.util.SortedMap |
valueTailMap(java.lang.Object value)
Method which returns a tailset of the values, or all the keys with values after to the specified value |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected java.util.SortedMap normal
protected java.util.SortedMap reverse
protected java.util.SortedMap nulls
Constructor Detail |
---|
public ReverseTreeMap()
protected ReverseTreeMap(java.util.SortedMap normal, java.util.SortedMap reverse, java.util.SortedMap nulls)
Method Detail |
---|
public int size()
public boolean containsKey(java.lang.Object key)
key
- THe key
public java.lang.Object get(java.lang.Object key)
key
- The key
public java.util.Set keySet()
public void remove(java.lang.Object key)
key
- The keypublic void put(java.lang.Object key, java.lang.Object value)
key
- The keyvalue
- The valuepublic java.util.SortedMap keyMap()
public java.util.SortedMap keyHeadMap(java.lang.Object value)
value
- The start value
public java.util.SortedMap keyTailMap(java.lang.Object value)
value
- The start value
public java.util.SortedMap keySubMap(java.lang.Object start, java.lang.Object end)
start
- The start valueend
- The end value
public java.util.SortedMap valueHeadMap(java.lang.Object value)
value
- The maximal valuepublic java.util.SortedMap valueTailMap(java.lang.Object value)
value
- The minimal valuepublic java.util.SortedMap valueSubMap(java.lang.Object start, java.lang.Object end)
value
- The maximal valuepublic java.util.SortedMap valueNullMap()
protected java.util.SortedMap convert(java.util.SortedMap map)
map
- THe map to convert
|
Rice Pastry API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |