|
Scala
1.2.0.1 |
|||
Field Summary | |
override
|
type This
The type returned when creating a new tree. |
Method Summary | |
def -(key: A): TreeMap[A,B]
Removes the key from the TreeMap. |
|
protected
|
def New(sz: Int, t: GBTree[A,Tuple2[A,B]]): TreeMap[A,B]
Creates a new TreeMap from a GBTree and its size. |
override
|
def apply(key: A): B
Retrieve the value which is associated with the given key. |
def elements: Iterator[Tuple2[A,B]]
Creates a new iterator over all elements contained in this object. |
|
def empty[C]: TreeMap[A,C]
A factory to create empty maps of the same type of keys. |
|
override
|
def entryKey(entry: Tuple2[A,B]): A
Returns the key of an entry. |
override
|
def equals(obj: Any): Boolean
Compares two maps structurally; i.e. |
override
|
def get(key: A): Option[B]
Check if this map maps key to a value and return the
value if it exists.
|
def insert(key: A, value: B): TreeMap[A,B]
A new TreeMap with the entry added is returned, assuming that key is not in the TreeMap. |
|
override
|
def toList: List[Tuple2[A,B]]
Creates a list of all (key, value) mappings. |
def update(key: A, value: B): TreeMap[A,B]
A new TreeMap with the entry added is returned, if key is not in the TreeMap, otherwise the key is updated with the new entry. |
Methods inherited from java/lang/Object-class |
clone, eq, finalize, getClass, notify, notifyAll, synchronized, wait, wait, wait |
Methods inherited from scala/Any-class |
!=, ==, asInstanceOf, isInstanceOf, match |
Methods inherited from scala/Iterable-class |
/:, :\, exists, find, foldLeft, foldRight, forall, foreach, sameElements |
Methods inherited from scala/collection/Map-class |
contains, exists, forall, foreach, isDefinedAt, isEmpty, keys, values |
Methods inherited from scala/collection/immutable/Map-class |
+, MapTo, excl, excl, filter, hashCode, incl, incl, map, mappingToString, toString |
Methods inherited from scala/collection/immutable/Tree-class |
GBNil, INode, ITree, aNode, add, balance, balance_list, balance_list_1, delete_any, entries, findValue, is_defined, size, tree, update_or_add |
Field Detail |
override type This = TreeMap[A,B]
class C[T](...) extends Tree[A,B](...) { type This = C[T];
Method Detail |
def empty[C]: TreeMap[A,C]
override def entryKey(entry: Tuple2[A,B]): A
protected def New(sz: Int, t: GBTree[A,Tuple2[A,B]]): TreeMap[A,B]
def update(key: A, value: B): TreeMap[A,B]
def insert(key: A, value: B): TreeMap[A,B]
def -(key: A): TreeMap[A,B]
override def get(key: A): Option[B]
key
to a value and return the
value if it exists.
key
-
the key of the mapping of interest
override def apply(key: A): B
key
-
the key
override def toList: List[Tuple2[A,B]]
def elements: Iterator[Tuple2[A,B]]
override def equals(obj: Any): Boolean
|
Scala
1.2.0.1 |
|||