in scala.collection.mutable
trait Map

[scala.cloneable]

abstract trait Map [A, B]
extends java.lang.Object
with scala.collection.Map[A, B]
with scala.collection.mutable.Scriptable[scala.collection.mutable.Message[scala.Tuple2[A, B]]]
with scala.ScalaObject
This class represents mutable maps. Concrete map implementations just have to provide functionality for the abstract methods in scala.collection.Map as well as for update, and remove.
Author:
Matthias Zenger
Version:
1.1, 09/05/2004
Direct Known Subclasses:
SynchronizedMap, ObservableMap, MultiMap, MapProxy, JavaMapAdaptor, ImmutableMapAdaptor, HashMap, DefaultMapModel

Class Summary
class MapTo



Def Summary
def ++= (it: scala.Iterator[scala.Tuple2[A, B]]) : scala.Unit
This method adds all the mappings provided by an iterator of parameter map to the map.
def ++= (map: scala.Iterable[scala.Tuple2[A, B]]) : scala.Unit
This method adds all the mappings provided by an iterator of parameter map to the map.
def += (key: A) : Map.this.MapTo
This method defines syntactic sugar for adding or modifying mappings. It is typically used in the following way:
    map += key -> value;
    

def --= (it: scala.Iterator[A]) : scala.Unit
This method removes all the mappings for keys provided by an iterator over the elements of the keys object.
def --= (keys: scala.Iterable[A]) : scala.Unit
This method removes all the mappings for keys provided by an iterator over the elements of the keys object.
abstract def -= (key: A) : scala.Unit
This method removes a mapping from the given key. If the map does not contain a mapping for the given key, the method does nothing.
def << (cmd: scala.collection.mutable.Message[scala.Tuple2[A, B]]) : scala.Unit
Send a message to this scriptable object.
def clear : scala.Unit
Removes all mappings from the map. After this operation is completed, the map is empty.
override def clone : scala.collection.mutable.Map[A, B]
Return a clone of this map.
def excl (keys: A*) : scala.Unit
This method will remove all the mappings for the given sequence of keys from the map.
def filter (p: scala.Function1[scala.Tuple2[A, B], scala.Boolean]) : scala.Unit
This method removes all the mappings for which the predicate p returns false.
override def hashCode : scala.Int
The hashCode method always yields an error, since it is not safe to use mutable maps as keys in hash tables.
def incl (mappings: scala.Tuple2[A,B]*) : scala.Unit
incl can be used to add many mappings at the same time to the map. The method assumes that a mapping is represented by a Pair object who's first component denotes the key, and who's second component refers to the value.
def map (f: scala.Function1[scala.Tuple2[A, B], B]) : scala.Unit
This function transforms all the values of mappings contained in this map with function f.
def mappingToString (p: scala.Tuple2[A, B]) : java.lang.String
This method controls how a mapping is represented in the string representation provided by method toString.
override def toString : java.lang.String
Returns a string representation of this map which shows all the mappings.
abstract def update (key: A, value: B) : scala.Unit
This method allows one to add a new mapping from key to value to the map. If the map already contains a mapping for key, it will be overridden by this function.


Def Detail
def ++= (it: scala.Iterator[scala.Tuple2[A, B]]): scala.Unit
This method adds all the mappings provided by an iterator of parameter map to the map.
Parameters:
it -

def ++= (map: scala.Iterable[scala.Tuple2[A, B]]): scala.Unit
This method adds all the mappings provided by an iterator of parameter map to the map.
Parameters:
map -

def += (key: A): Map.this.MapTo
This method defines syntactic sugar for adding or modifying mappings. It is typically used in the following way:
    map += key -> value;
    

def --= (it: scala.Iterator[A]): scala.Unit
This method removes all the mappings for keys provided by an iterator over the elements of the keys object.
Parameters:
it -

def --= (keys: scala.Iterable[A]): scala.Unit
This method removes all the mappings for keys provided by an iterator over the elements of the keys object.
Parameters:
keys -

abstract def -= (key: A): scala.Unit
This method removes a mapping from the given key. If the map does not contain a mapping for the given key, the method does nothing.
Parameters:
key -

def << (cmd: scala.collection.mutable.Message[scala.Tuple2[A, B]]): scala.Unit
Send a message to this scriptable object.
Parameters:
cmd - the message to send.

def clear : scala.Unit
Removes all mappings from the map. After this operation is completed, the map is empty.

override def clone : scala.collection.mutable.Map[A, B]
Return a clone of this map.
Returns:
a map with the same elements.

def excl (keys: A*): scala.Unit
This method will remove all the mappings for the given sequence of keys from the map.
Parameters:
keys -

def filter (p: scala.Function1[scala.Tuple2[A, B], scala.Boolean]): scala.Unit
This method removes all the mappings for which the predicate p returns false.
Parameters:
p -

override def hashCode : scala.Int
The hashCode method always yields an error, since it is not safe to use mutable maps as keys in hash tables.
Returns:
never.

def incl (mappings: scala.Tuple2[A,B]*): scala.Unit
incl can be used to add many mappings at the same time to the map. The method assumes that a mapping is represented by a Pair object who's first component denotes the key, and who's second component refers to the value.
Parameters:
mappings -

def map (f: scala.Function1[scala.Tuple2[A, B], B]): scala.Unit
This function transforms all the values of mappings contained in this map with function f.
Parameters:
f -

def mappingToString (p: scala.Tuple2[A, B]): java.lang.String
This method controls how a mapping is represented in the string representation provided by method toString.
Parameters:
p -

override def toString : java.lang.String
Returns a string representation of this map which shows all the mappings.

abstract def update (key: A, value: B): scala.Unit
This method allows one to add a new mapping from key to value to the map. If the map already contains a mapping for key, it will be overridden by this function.
Parameters:
key -
Parameters:
value -