HashMultiMap

scalation.database.HashMultiMap
class HashMultiMap[K, V](initialCap: Int, loadFactor: Double)(implicit evidence$1: ClassTag[K], evidence$2: ClassTag[V]) extends Serializable

The HashMultiMap class provides hash maps that use the Separate Chaining algorithm. It build on HashMap allowing values to multi-valued Set [V] and can be used for building Non-Unique Indices.

Type parameters

K

the type of the keys contained in this hash map

V

the base-type of the values assigned to keys in this hash map

Value parameters

initialCap

the initial hash table size (number of slots)

loadFactor

the load factor (number of keys over number of slots)

Attributes

See also

scala.collection.mutable.HashMap

Graph
Supertypes
trait Serializable
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

def addOne1(elem: (K, V)): hmap.type

Add one key-value pair into this hash map and return this (called by put). The addOne method adds a set of values, whereas addOne1 adds a single value.

Add one key-value pair into this hash map and return this (called by put). The addOne method adds a set of values, whereas addOne1 adds a single value.

Value parameters

elem

the key-value pair to add/insert for an individual value

Attributes

def show(): Unit

Show/print this HashMap.

Show/print this HashMap.

Attributes

Concrete fields

val count: Int

Exports

Defined exports

final def ++[B >: IterableOps.this.A](suffix: IterableOnce[B]): IterableOps.this.CC[B]
Exported from IterableOps
def ++[V2 >: MapOps.this.V](xs: IterableOnce[(MapOps.this.K, V2)]): MapOps.this.CC[MapOps.this.K, V2]
Exported from MapOps
protected val ++=: HashMap[K, Set[V]]
Exported from HashMultiMap
protected val +=: HashMap[K, Set[V]]
Exported from HashMultiMap
protected val +=: HashMap[K, Set[V]]
Exported from HashMultiMap
protected val --=: HashMap[K, Set[V]]
Exported from HashMultiMap
protected val -=: HashMap[K, Set[V]]
Exported from HashMultiMap
protected val -=: HashMap[K, Set[V]]
Exported from HashMultiMap
protected val addAll: HashMap[K, Set[V]]
Exported from HashMultiMap
protected val addOne: HashMap[K, Set[V]]
Exported from HashMultiMap
val addString: StringBuilder
Exported from addString
val addString: StringBuilder
Exported from addString
val addString: StringBuilder
Exported from addString
def andThen[C](k: PartialFunction[PartialFunction.this.B, C]): PartialFunction[PartialFunction.this.A, C]
Exported from PartialFunction
override def andThen[C](k: PartialFunction.this.B => C): PartialFunction[PartialFunction.this.A, C]
Exported from PartialFunction
override def applyOrElse[K1 <: MapOps.this.K, V1 >: MapOps.this.V](x: K1, default: K1 => V1): V1
Exported from MapOps
override def collect[B](pf: PartialFunction[StrictOptimizedIterableOps.this.A, B]): StrictOptimizedIterableOps.this.CC[B]
Exported from StrictOptimizedIterableOps
override def collect[K2, V2](pf: PartialFunction[(StrictOptimizedMapOps.this.K, StrictOptimizedMapOps.this.V), (K2, V2)]): StrictOptimizedMapOps.this.CC[K2, V2]
Exported from StrictOptimizedMapOps
def collectFirst[B](pf: PartialFunction[IterableOnceOps.this.A, B]): Option[B]
Exported from IterableOnceOps
def compose[R](k: PartialFunction[R, PartialFunction.this.A]): PartialFunction[R, PartialFunction.this.B]
Exported from PartialFunction
def compose[A](g: A => Function1.this.T1): A => Function1.this.R
Exported from Function1
def concat[B >: IterableOps.this.A](suffix: IterableOnce[B]): IterableOps.this.CC[B]
Exported from IterableOps
override def concat[V2 >: StrictOptimizedMapOps.this.V](suffix: IterableOnce[(StrictOptimizedMapOps.this.K, V2)]): StrictOptimizedMapOps.this.CC[StrictOptimizedMapOps.this.K, V2]
Exported from StrictOptimizedMapOps
def copyToArray[B >: IterableOnceOps.this.A](xs: Array[B], start: Int, len: Int): Int
Exported from IterableOnceOps
def copyToArray[B >: IterableOnceOps.this.A](xs: Array[B], start: Int): Int
Exported from IterableOnceOps
def copyToArray[B >: IterableOnceOps.this.A](xs: Array[B]): Int
Exported from IterableOnceOps
def elementWise: ElementWiseExtractor[PartialFunction.this.A, PartialFunction.this.B]
Exported from PartialFunction
override def empty: MapFactoryDefaults.this.CC[MapFactoryDefaults.this.K, MapFactoryDefaults.this.V]
Exported from MapFactoryDefaults
protected val filterInPlace: HashMap[K, Set[V]]
Exported from HashMultiMap
override def flatMap[B](f: StrictOptimizedIterableOps.this.A => IterableOnce[B]): StrictOptimizedIterableOps.this.CC[B]
Exported from StrictOptimizedIterableOps
override def flatMap[K2, V2](f: ((StrictOptimizedMapOps.this.K, StrictOptimizedMapOps.this.V)) => IterableOnce[(K2, V2)]): StrictOptimizedMapOps.this.CC[K2, V2]
Exported from StrictOptimizedMapOps
override def flatten[B](implicit toIterableOnce: StrictOptimizedIterableOps.this.A => IterableOnce[B]): StrictOptimizedIterableOps.this.CC[B]
Exported from StrictOptimizedIterableOps
override def foreach[U](f: ((HashMap.this.K, HashMap.this.V)) => U): Unit
Exported from HashMap
override def foreachEntry[U](f: (HashMap.this.K, HashMap.this.V) => U): Unit
Exported from HashMap
override def getOrElse[V1 >: HashMap.this.V](key: HashMap.this.K, default: => V1): V1
Exported from HashMap
def groupBy[K](f: IterableOps.this.A => K): Map[K, IterableOps.this.C]
Exported from IterableOps
def head: IterableOps.this.A
Exported from IterableOps
def headOption: Option[IterableOps.this.A]
Exported from IterableOps
def init: IterableOps.this.C
Exported from IterableOps
def inits: Iterator[IterableOps.this.C]
Exported from IterableOps
override def isEmpty: Boolean
Exported from HashMap
override def isTraversableAgain: Boolean
Exported from IterableOps
override def iterableFactory: IterableFactory[Iterable]
Exported from Iterable
override def iterator: Iterator[(HashMap.this.K, HashMap.this.V)]
Exported from HashMap
def keySet: Set[MapOps.this.K]
Exported from MapOps
override def keyStepper[S <: Stepper[_]](implicit shape: StepperShape[HashMap.this.K, S]): S & EfficientSplit
Exported from HashMap
def keys: Iterable[MapOps.this.K]
Exported from MapOps
override def keysIterator: Iterator[HashMap.this.K]
Exported from HashMap
override def knownSize: Int
Exported from HashMap
def last: IterableOps.this.A
Exported from IterableOps
def lastOption: Option[IterableOps.this.A]
Exported from IterableOps
def lazyZip[B](that: Iterable[B]): LazyZip2[Iterable.this.A, B, Iterable.this.type]
Exported from Iterable
def lift: PartialFunction.this.A => Option[PartialFunction.this.B]
Exported from PartialFunction
override def map[B](f: StrictOptimizedIterableOps.this.A => B): StrictOptimizedIterableOps.this.CC[B]
Exported from StrictOptimizedIterableOps
override def map[K2, V2](f: ((StrictOptimizedMapOps.this.K, StrictOptimizedMapOps.this.V)) => (K2, V2)): StrictOptimizedMapOps.this.CC[K2, V2]
Exported from StrictOptimizedMapOps
override def mapFactory: MapFactory[HashMap]
Exported from HashMap
def mapResult[NewTo](f: Builder.this.To => NewTo): Builder[Builder.this.A, NewTo]
Exported from Builder
protected val mapValuesInPlace: HashMap[K, Set[V]]
Exported from HashMultiMap
def max[B >: IterableOnceOps.this.A](implicit ord: Ordering[B]): IterableOnceOps.this.A
Exported from IterableOnceOps
def maxOption[B >: IterableOnceOps.this.A](implicit ord: Ordering[B]): Option[IterableOnceOps.this.A]
Exported from IterableOnceOps
def min[B >: IterableOnceOps.this.A](implicit ord: Ordering[B]): IterableOnceOps.this.A
Exported from IterableOnceOps
def minOption[B >: IterableOnceOps.this.A](implicit ord: Ordering[B]): Option[IterableOnceOps.this.A]
Exported from IterableOnceOps
final def mkString: String
Exported from IterableOnceOps
def nonEmpty: Boolean
Exported from IterableOnceOps
def orElse[A1 <: PartialFunction.this.A, B1 >: PartialFunction.this.B](that: PartialFunction[A1, B1]): PartialFunction[A1, B1]
Exported from PartialFunction
override def partitionMap[A1, A2](f: StrictOptimizedIterableOps.this.A => Either[A1, A2]): (StrictOptimizedIterableOps.this.CC[A1], StrictOptimizedIterableOps.this.CC[A2])
Exported from StrictOptimizedIterableOps
def product[B >: IterableOnceOps.this.A](implicit num: Numeric[B]): B
Exported from IterableOnceOps
def reduce[B >: IterableOnceOps.this.A](op: (B, B) => B): B
Exported from IterableOnceOps
def reduceLeft[B >: IterableOnceOps.this.A](op: (B, IterableOnceOps.this.A) => B): B
Exported from IterableOnceOps
def reduceLeftOption[B >: IterableOnceOps.this.A](op: (B, IterableOnceOps.this.A) => B): Option[B]
Exported from IterableOnceOps
def reduceOption[B >: IterableOnceOps.this.A](op: (B, B) => B): Option[B]
Exported from IterableOnceOps
def reduceRight[B >: IterableOnceOps.this.A](op: (IterableOnceOps.this.A, B) => B): B
Exported from IterableOnceOps
def reduceRightOption[B >: IterableOnceOps.this.A](op: (IterableOnceOps.this.A, B) => B): Option[B]
Exported from IterableOnceOps
protected val retain: HashMap[K, Set[V]]
Exported from HashMultiMap
def runWith[U](action: PartialFunction.this.B => U): PartialFunction.this.A => Boolean
Exported from PartialFunction
override def size: Int
Exported from HashMap
final def sizeIs: SizeCompareOps
Exported from IterableOps
override def stepper[S <: Stepper[_]](implicit shape: StepperShape[(HashMap.this.K, HashMap.this.V), S]): S & EfficientSplit
Exported from HashMap
protected val subtractAll: HashMap[K, Set[V]]
Exported from HashMultiMap
protected val subtractOne: HashMap[K, Set[V]]
Exported from HashMultiMap
def sum[B >: IterableOnceOps.this.A](implicit num: Numeric[B]): B
Exported from IterableOnceOps
def tail: IterableOps.this.C
Exported from IterableOps
def tails: Iterator[IterableOps.this.C]
Exported from IterableOps
override def tapEach[U](f: StrictOptimizedIterableOps.this.A => U): StrictOptimizedIterableOps.this.C
Exported from StrictOptimizedIterableOps
def to[C1](factory: Factory[IterableOnceOps.this.A, C1]): C1
Exported from IterableOnceOps
def toArray[B >: IterableOnceOps.this.A : ClassTag]: Array[B]
Exported from IterableOnceOps
final def toBuffer[B >: IterableOnceOps.this.A]: Buffer[B]
Exported from IterableOnceOps
def toIndexedSeq: IndexedSeq[IterableOnceOps.this.A]
Exported from IterableOnceOps
def toList: List[IterableOnceOps.this.A]
Exported from IterableOnceOps
def toMap[K, V](implicit ev: IterableOnceOps.this.A <:< (K, V)): Map[K, V]
Exported from IterableOnceOps
def toSeq: Seq[IterableOnceOps.this.A]
Exported from IterableOnceOps
def toSet[B >: IterableOnceOps.this.A]: Set[B]
Exported from IterableOnceOps
def toVector: Vector[IterableOnceOps.this.A]
Exported from IterableOnceOps
protected val transform: HashMap[K, Set[V]]
Exported from HashMultiMap
def transpose[B](implicit asIterable: IterableOps.this.A => Iterable[B]): IterableOps.this.CC[IterableOps.this.CC[B]]
Exported from IterableOps
override def unzip[A1, A2](implicit asPair: StrictOptimizedIterableOps.this.A => (A1, A2)): (StrictOptimizedIterableOps.this.CC[A1], StrictOptimizedIterableOps.this.CC[A2])
Exported from StrictOptimizedIterableOps
override def unzip3[A1, A2, A3](implicit asTriple: StrictOptimizedIterableOps.this.A => (A1, A2, A3)): (StrictOptimizedIterableOps.this.CC[A1], StrictOptimizedIterableOps.this.CC[A2], StrictOptimizedIterableOps.this.CC[A3])
Exported from StrictOptimizedIterableOps
override def valueStepper[S <: Stepper[_]](implicit shape: StepperShape[HashMap.this.V, S]): S & EfficientSplit
Exported from HashMap
def values: Iterable[MapOps.this.V]
Exported from MapOps
override def valuesIterator: Iterator[HashMap.this.V]
Exported from HashMap
override def view: MapView[MapOps.this.K, MapOps.this.V]
Exported from MapOps
override def zip[B](that: IterableOnce[B]): StrictOptimizedIterableOps.this.CC[(StrictOptimizedIterableOps.this.A, B)]
Exported from StrictOptimizedIterableOps
def zipAll[A1 >: IterableOps.this.A, B](that: Iterable[B], thisElem: A1, thatElem: B): IterableOps.this.CC[(A1, B)]
Exported from IterableOps
override def zipWithIndex: StrictOptimizedIterableOps.this.CC[(StrictOptimizedIterableOps.this.A, Int)]
Exported from StrictOptimizedIterableOps

Deprecated defined exports

override def +[V1 >: StrictOptimizedMapOps.this.V](elem1: (StrictOptimizedMapOps.this.K, V1), elem2: (StrictOptimizedMapOps.this.K, V1), elems: (StrictOptimizedMapOps.this.K, V1)*): StrictOptimizedMapOps.this.CC[StrictOptimizedMapOps.this.K, V1]
Exported from StrictOptimizedMapOps

Attributes

Deprecated
[Since version 2.13.0] Use ++ with an explicit collection argument instead of + with varargs
def +[V1 >: MapOps.this.V](kv: (MapOps.this.K, V1)): MapOps.this.CC[MapOps.this.K, V1]
Exported from MapOps

Attributes

Deprecated
[Since version 2.13.0] Consider requiring an immutable Map or fall back to Map.concat.
def ++:[B >: IterableOps.this.A](that: IterableOnce[B]): IterableOps.this.CC[B]
Exported from IterableOps

Attributes

Deprecated
[Since version 2.13.0] Use ++ instead of ++: for collections of type Iterable
def ++:[V1 >: MapOps.this.V](that: IterableOnce[(MapOps.this.K, V1)]): MapOps.this.CC[MapOps.this.K, V1]
Exported from MapOps

Attributes

Deprecated
[Since version 2.13.0] Use ++ instead of ++: for collections of type Iterable
def companion: IterableFactory[IterableOps.this.CC]
Exported from IterableOps

Attributes

Deprecated
[Since version 2.13.0] Use iterableFactory instead
final def copyToBuffer[B >: IterableOnceOps.this.A](dest: Buffer[B]): Unit
Exported from IterableOnceOps

Attributes

Deprecated
[Since version 2.13.0] Use `dest ++= coll` instead
def hasDefiniteSize: Boolean
Exported from IterableOnceOps

Attributes

Deprecated
[Since version 2.13.0] Check .knownSize instead of .hasDefiniteSize for more actionable information (see scaladoc for details)
def mapValues[W](f: MapOps.this.V => W): MapView[MapOps.this.K, W]
Exported from MapOps

Attributes

Deprecated
[Since version 2.13.0] Use .view.mapValues(f). A future version will include a strict version of this method (for now, .view.mapValues(f).toMap).
final def repr: IterableOps.this.C
Exported from IterableOps

Attributes

Deprecated
[Since version 2.13.0] Use coll instead of repr in a collection implementation, use the collection value itself from the outside
def seq: Iterable.this.type
Exported from Iterable

Attributes

Deprecated
[Since version 2.13.0] Iterable.seq always returns the iterable itself
final def toIterable: Iterable.this.type
Exported from Iterable

Attributes

Deprecated
[Since version 2.13.7] toIterable is internal and will be made protected; its name is similar to `toList` or `toSeq`, but it doesn\'t copy non-immutable collections
final def toIterator: Iterator[IterableOnceOps.this.A]
Exported from IterableOnceOps

Attributes

Deprecated
[Since version 2.13.0] Use .iterator instead of .toIterator
final def toStream: Stream[IterableOnceOps.this.A]
Exported from IterableOnceOps

Attributes

Deprecated
[Since version 2.13.0] Use .to(LazyList) instead of .toStream
final def toTraversable: Iterable[IterableOps.this.A]
Exported from IterableOps

Attributes

Deprecated
[Since version 2.13.0] toTraversable is internal and will be made protected; its name is similar to `toList` or `toSeq`, but it doesn\'t copy non-immutable collections
def updated[V1 >: MapOps.this.V](key: MapOps.this.K, value: V1): MapOps.this.CC[MapOps.this.K, V1]
Exported from MapOps

Attributes

Deprecated
[Since version 2.13.0] Use m.clone().addOne((k,v)) instead of m.updated(k, v)