MultiMapSorted

intervalidus.collection.mutable.MultiMapSorted
See theMultiMapSorted companion object
class MultiMapSorted[K, V] extends MultiMapSortedLike[K, V]

A multimap where multiple values can be associated with the same key. Similar to SortedMultiDict in scala-collection-contrib, but this returns values in order (values are stored in a sorted set), not keys. Also, this only implements a small subset of methods needed in this project.

Type parameters

K

key type

V

value type (uses Ordering[V])

Attributes

Companion
object
Source
MultiMapSorted.scala
Graph
Supertypes
trait MultiMapSortedLike[K, V]
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

def addAll(elems: Iterable[(K, V)]): Unit

Associate many keys and values.

Associate many keys and values.

Value parameters

elems

key-value pairs to associate.

Attributes

Source
MultiMapSorted.scala
def addOne(elem: (K, V)): Unit

Associate a value with a key.

Associate a value with a key.

Value parameters

elem

a key-value pair to associate.

Attributes

Source
MultiMapSorted.scala
def clear(): Unit

Clear all associations.

Clear all associations.

Attributes

Source
MultiMapSorted.scala
override def clone(): MultiMapSorted[K, V]

Create a copy of the receiver object.

Create a copy of the receiver object.

The default implementation of the clone method is platform dependent.

Attributes

Returns

a copy of the receiver object.

Note

not specified by SLS as a member of AnyRef

Definition Classes
Object
Source
MultiMapSorted.scala
def subtractOne(elem: (K, V)): Unit

Disassociate a value from a key.

Disassociate a value from a key.

Value parameters

elem

a key-value pair which should no longer be associated.

Attributes

Source
MultiMapSorted.scala

Inherited methods

def get(key: K): Iterable[V]

Retrieves in order all the values associated with the given key.

Retrieves in order all the values associated with the given key.

Value parameters

key

the key.

Attributes

Returns

the values associated with the given key.

Inherited from:
MultiMapSortedLike
Source
MultiMapSortedLike.scala
def keySet: Set[K]

Collects all keys of this map in a set.

Collects all keys of this map in a set.

Attributes

Returns

a set containing all keys of this multimap.

Inherited from:
MultiMapSortedLike
Source
MultiMapSortedLike.scala