Instance Constructors
-
new
TransactionalMap
()
-
new
TransactionalMap
(initialValue: HashMap[K, V])
Type Members
-
type
Self
= Map[K, V]
Value Members
-
def
!=
(arg0: AnyRef): Boolean
-
def
!=
(arg0: Any): Boolean
-
def
##
(): Int
-
def
+
[B1 >: V]
(elem1: (K, B1), elem2: (K, B1), elems: (K, B1)*): Map[K, B1]
-
def
+
[B1 >: V]
(kv: (K, B1)): Map[K, B1]
-
def
++
[B1 >: V]
(xs: TraversableOnce[(K, B1)]): Map[K, B1]
-
def
++
[B1 >: V]
(xs: GenTraversableOnce[(K, B1)]): Map[K, B1]
-
def
++
[B >: (K, V), That]
(that: TraversableOnce[B])(implicit bf: CanBuildFrom[Map[K, V], B, That]): That
-
def
++
[B >: (K, V), That]
(that: GenTraversableOnce[B])(implicit bf: CanBuildFrom[Map[K, V], B, That]): That
-
def
++:
[B >: (K, V), That]
(that: Traversable[B])(implicit bf: CanBuildFrom[Map[K, V], B, That]): That
-
def
++:
[B >: (K, V), That]
(that: TraversableOnce[B])(implicit bf: CanBuildFrom[Map[K, V], B, That]): That
-
def
++=
(xs: TraversableOnce[(K, V)]): TransactionalMap.this.type
-
def
+=
(kv: (K, V)): TransactionalMap.this.type
-
def
+=
(key: K, value: V): Option[V]
-
def
+=
(elem1: (K, V), elem2: (K, V), elems: (K, V)*): TransactionalMap.this.type
-
def
-
(elem1: K, elem2: K, elems: K*): Map[K, V]
-
def
-
(key: K): Map[K, V]
-
def
--
(xs: TraversableOnce[K]): Map[K, V]
-
def
--
(xs: GenTraversableOnce[K]): Map[K, V]
-
def
--=
(xs: TraversableOnce[K]): TransactionalMap.this.type
-
def
-=
(key: K): TransactionalMap.this.type
-
def
-=
(elem1: K, elem2: K, elems: K*): TransactionalMap.this.type
-
def
/:
[B]
(z: B)(op: (B, (K, V)) ⇒ B): B
-
def
/:\
[A1 >: (K, V)]
(z: A1)(op: (A1, A1) ⇒ A1): A1
-
def
:\
[B]
(z: B)(op: ((K, V), B) ⇒ B): B
-
def
==
(arg0: AnyRef): Boolean
-
def
==
(arg0: Any): Boolean
-
def
addString
(b: StringBuilder, start: String, sep: String, end: String): StringBuilder
-
def
addString
(b: StringBuilder): StringBuilder
-
def
addString
(b: StringBuilder, sep: String): StringBuilder
-
def
aggregate
[B]
(z: B)(seqop: (B, (K, V)) ⇒ B, combop: (B, B) ⇒ B): B
-
def
andThen
[C]
(k: (V) ⇒ C): PartialFunction[K, C]
-
def
apply
(key: K): V
-
def
asInstanceOf
[T0]
: T0
-
def
canEqual
(that: Any): Boolean
-
def
clear
(): Unit
-
def
clone
(): Map[K, V]
-
def
collect
[B, That]
(pf: PartialFunction[(K, V), B])(implicit bf: CanBuildFrom[Map[K, V], B, That]): That
-
def
collectFirst
[B]
(pf: PartialFunction[(K, V), B]): Option[B]
-
def
companion
: GenericCompanion[Iterable]
-
def
compose
[A]
(g: (A) ⇒ K): (A) ⇒ V
-
def
contains
(key: K): Boolean
-
def
copyToArray
[B >: (K, V)]
(xs: Array[B], start: Int, len: Int): Unit
-
def
copyToArray
[B >: (K, V)]
(xs: Array[B]): Unit
-
def
copyToArray
[B >: (K, V)]
(xs: Array[B], start: Int): Unit
-
def
copyToBuffer
[B >: (K, V)]
(dest: Buffer[B]): Unit
-
def
count
(p: ((K, V)) ⇒ Boolean): Int
-
def
default
(key: K): V
-
def
drop
(n: Int): Map[K, V]
-
def
dropRight
(n: Int): Map[K, V]
-
def
dropWhile
(p: ((K, V)) ⇒ Boolean): Map[K, V]
-
def
elements
: Iterator[(K, V)]
-
def
empty
: Map[K, V]
-
def
eq
(arg0: AnyRef): Boolean
-
def
equals
(other: Any): Boolean
-
def
exists
(p: ((K, V)) ⇒ Boolean): Boolean
-
def
filter
(p: ((K, V)) ⇒ Boolean): Map[K, V]
-
def
filterKeys
(p: (K) ⇒ Boolean): Map[K, V]
-
def
filterNot
(p: ((K, V)) ⇒ Boolean): Map[K, V]
-
def
finalize
(): Unit
-
def
find
(p: ((K, V)) ⇒ Boolean): Option[(K, V)]
-
def
flatMap
[B, That]
(f: ((K, V)) ⇒ GenTraversableOnce[B])(implicit bf: CanBuildFrom[Map[K, V], B, That]): That
-
def
flatten
[B]
(implicit asTraversable: ((K, V)) ⇒ TraversableOnce[B]): Traversable[B]
-
def
fold
[A1 >: (K, V)]
(z: A1)(op: (A1, A1) ⇒ A1): A1
-
def
foldLeft
[B]
(z: B)(op: (B, (K, V)) ⇒ B): B
-
def
foldRight
[B]
(z: B)(op: ((K, V), B) ⇒ B): B
-
def
forall
(p: ((K, V)) ⇒ Boolean): Boolean
-
def
foreach
[U]
(f: ((K, V)) ⇒ U): Unit
-
def
genericBuilder
[B]
: Builder[B, Iterable[B]]
-
def
get
(key: K): Option[V]
-
def
getClass
(): java.lang.Class[_]
-
def
getOrElse
[B1 >: V]
(key: K, default: ⇒ B1): B1
-
def
getOrElseUpdate
(key: K, op: ⇒ V): V
-
def
groupBy
[K]
(f: ((K, V)) ⇒ K): Map[K, Map[K, V]]
-
def
grouped
(size: Int): Iterator[Map[K, V]]
-
def
hasDefiniteSize
: Boolean
-
def
hashCode
(): Int
-
def
head
: (K, V)
-
def
headOption
: Option[(K, V)]
-
def
init
: Map[K, V]
-
def
inits
: Iterator[Map[K, V]]
-
def
isDefinedAt
(key: K): Boolean
-
def
isEmpty
: Boolean
-
def
isInstanceOf
[T0]
: Boolean
-
def
isTraversableAgain
: Boolean
-
def
iterator
: Iterator[(K, V)]
-
def
keySet
: Set[K]
-
def
keys
: Iterable[K]
-
def
keysIterator
: Iterator[K]
-
def
last
: (K, V)
-
def
lastOption
: Option[(K, V)]
-
def
lift
: (K) ⇒ Option[V]
-
def
map
[B, That]
(f: ((K, V)) ⇒ B)(implicit bf: CanBuildFrom[Map[K, V], B, That]): That
-
def
mapResult
[NewTo]
(f: (Map[K, V]) ⇒ NewTo): Builder[(K, V), NewTo]
-
def
mapValues
[C]
(f: (V) ⇒ C): Map[K, C]
-
def
max
[B >: (K, V)]
(implicit cmp: Ordering[B]): (K, V)
-
def
maxBy
[B]
(f: ((K, V)) ⇒ B)(implicit cmp: Ordering[B]): (K, V)
-
def
min
[B >: (K, V)]
(implicit cmp: Ordering[B]): (K, V)
-
def
minBy
[B]
(f: ((K, V)) ⇒ B)(implicit cmp: Ordering[B]): (K, V)
-
def
mkString
: String
-
def
mkString
(sep: String): String
-
def
mkString
(start: String, sep: String, end: String): String
-
def
ne
(arg0: AnyRef): Boolean
-
def
newBuilder
: Builder[(K, V), Map[K, V]]
-
def
nonEmpty
: Boolean
-
def
notify
(): Unit
-
def
notifyAll
(): Unit
-
def
orElse
[A1 <: K, B1 >: V]
(that: PartialFunction[A1, B1]): PartialFunction[A1, B1]
-
def
par
: ParMap[K, V]
-
def
parCombiner
: Combiner[(K, V), ParMap[K, V]]
-
def
partition
(p: ((K, V)) ⇒ Boolean): (Map[K, V], Map[K, V])
-
def
product
[B >: (K, V)]
(implicit num: Numeric[B]): B
-
def
put
(key: K, value: V): Option[V]
-
def
reduce
[A1 >: (K, V)]
(op: (A1, A1) ⇒ A1): A1
-
def
reduceLeft
[B >: (K, V)]
(op: (B, (K, V)) ⇒ B): B
-
def
reduceLeftOption
[B >: (K, V)]
(op: (B, (K, V)) ⇒ B): Option[B]
-
def
reduceOption
[A1 >: (K, V)]
(op: (A1, A1) ⇒ A1): Option[A1]
-
def
reduceRight
[B >: (K, V)]
(op: ((K, V), B) ⇒ B): B
-
def
reduceRightOption
[B >: (K, V)]
(op: ((K, V), B) ⇒ B): Option[B]
-
def
remove
(key: K): Option[V]
-
def
repr
: Map[K, V]
-
def
result
(): Map[K, V]
-
def
retain
(p: (K, V) ⇒ Boolean): TransactionalMap.this.type
-
def
reversed
: List[(K, V)]
-
def
sameElements
[B >: (K, V)]
(that: Iterable[B]): Boolean
-
def
sameElements
[B >: (K, V)]
(that: GenIterable[B]): Boolean
-
def
scan
[B >: (K, V), That]
(z: B)(op: (B, B) ⇒ B)(implicit cbf: CanBuildFrom[Map[K, V], B, That]): That
-
def
scanLeft
[B, That]
(z: B)(op: (B, (K, V)) ⇒ B)(implicit bf: CanBuildFrom[Map[K, V], B, That]): That
-
def
scanRight
[B, That]
(z: B)(op: ((K, V), B) ⇒ B)(implicit bf: CanBuildFrom[Map[K, V], B, That]): That
-
def
seq
: Map[K, V]
-
def
size
: Int
-
def
sizeHint
(coll: scala.collection.TraversableLike[_, _], delta: Int): Unit
-
def
sizeHint
(size: Int): Unit
-
def
sizeHintBounded
(size: Int, boundingColl: scala.collection.TraversableLike[_, _]): Unit
-
def
slice
(from: Int, until: Int): Map[K, V]
-
def
sliding
[B >: (K, V)]
(size: Int, step: Int): Iterator[Map[K, V]]
-
def
sliding
[B >: (K, V)]
(size: Int): Iterator[Map[K, V]]
-
def
span
(p: ((K, V)) ⇒ Boolean): (Map[K, V], Map[K, V])
-
def
splitAt
(n: Int): (Map[K, V], Map[K, V])
-
def
stringPrefix
: String
-
def
sum
[B >: (K, V)]
(implicit num: Numeric[B]): B
-
def
synchronized
[T0]
(arg0: ⇒ T0): T0
-
def
tail
: Map[K, V]
-
def
tails
: Iterator[Map[K, V]]
-
def
take
(n: Int): Map[K, V]
-
def
takeRight
(n: Int): Map[K, V]
-
def
takeWhile
(p: ((K, V)) ⇒ Boolean): Map[K, V]
-
def
thisCollection
: Iterable[(K, V)]
-
def
toArray
[B >: (K, V)]
(implicit arg0: ClassManifest[B]): Array[B]
-
def
toBuffer
[C >: (K, V)]
: Buffer[C]
-
def
toCollection
(repr: Map[K, V]): Iterable[(K, V)]
-
def
toIndexedSeq
[B >: (K, V)]
: IndexedSeq[B]
-
def
toIterable
: Iterable[(K, V)]
-
def
toIterator
: Iterator[(K, V)]
-
def
toList
: List[(K, V)]
-
def
toMap
[T, U]
(implicit ev: <:<[(K, V), (T, U)]): Map[T, U]
-
def
toSeq
: Seq[(K, V)]
-
def
toSet
[B >: (K, V)]
: Set[B]
-
def
toStream
: Stream[(K, V)]
-
def
toString
(): String
-
def
toTraversable
: Traversable[(K, V)]
-
def
transform
(f: (K, V) ⇒ V): TransactionalMap.this.type
-
def
transpose
[B]
(implicit asTraversable: ((K, V)) ⇒ TraversableOnce[B]): Traversable[Traversable[B]]
-
def
unzip
[A1, A2]
(implicit asPair: ((K, V)) ⇒ (A1, A2)): (Iterable[A1], Iterable[A2])
-
def
unzip3
[A1, A2, A3]
(implicit asTriple: ((K, V)) ⇒ (A1, A2, A3)): (Iterable[A1], Iterable[A2], Iterable[A3])
-
def
update
(key: K, value: V): Unit
-
def
updated
[B1 >: V]
(key: K, value: B1): Map[K, B1]
-
val
uuid
: String
-
def
values
: Iterable[V]
-
def
valuesIterator
: Iterator[V]
-
def
view
(from: Int, until: Int): IterableView[(K, V), Map[K, V]]
-
def
view
: IterableView[(K, V), Map[K, V]]
-
def
wait
(): Unit
-
def
wait
(arg0: Long, arg1: Int): Unit
-
def
wait
(arg0: Long): Unit
-
def
withDefault
(d: (K) ⇒ V): Map[K, V]
-
def
withDefaultValue
(d: V): Map[K, V]
-
def
withFilter
(p: ((K, V)) ⇒ Boolean): FilterMonadic[(K, V), Map[K, V]]
-
def
zip
[A1 >: (K, V), B, That]
(that: Iterable[B])(implicit bf: CanBuildFrom[Map[K, V], (A1, B), That]): That
-
def
zip
[A1 >: (K, V), B, That]
(that: GenIterable[B])(implicit bf: CanBuildFrom[Map[K, V], (A1, B), That]): That
-
def
zipAll
[B, A1 >: (K, V), That]
(that: Iterable[B], thisElem: A1, thatElem: B)(implicit bf: CanBuildFrom[Map[K, V], (A1, B), That]): That
-
def
zipAll
[B, A1 >: (K, V), That]
(that: GenIterable[B], thisElem: A1, thatElem: B)(implicit bf: CanBuildFrom[Map[K, V], (A1, B), That]): That
-
def
zipWithIndex
[A1 >: (K, V), That]
(implicit bf: CanBuildFrom[Map[K, V], (A1, Int), That]): That
Deprecated Value Members
-
def
first
: (K, V)
-
def
firstOption
: Option[(K, V)]
-
def
mapElements
[C]
(f: (V) ⇒ C): Map[K, C]
-
def
projection
: IterableView[(K, V), Map[K, V]]
-
def
removeKey
(key: K): Option[V]
Inherited from Map[K, V]
Inherited from MapLike[K, V, Map[K, V]]
Inherited from Cloneable[Map[K, V]]
Inherited from Shrinkable[K]
Inherited from Builder[(K, V), Map[K, V]]
Inherited from Growable[(K, V)]
Inherited from Map[K, V]
Inherited from MapLike[K, V, Map[K, V]]
Inherited from Subtractable[K, Map[K, V]]
Inherited from PartialFunction[K, V]
Inherited from (K) ⇒ V
Inherited from GenMap[K, V]
Inherited from GenMapLike[K, V, Map[K, V]]
Inherited from Iterable[(K, V)]
Inherited from Iterable[(K, V)]
Inherited from IterableLike[(K, V), Map[K, V]]
Inherited from Equals
Inherited from GenIterable[(K, V)]
Inherited from GenIterableLike[(K, V), Map[K, V]]
Inherited from Traversable[(K, V)]
Inherited from Mutable
Inherited from Traversable[(K, V)]
Inherited from GenTraversable[(K, V)]
Inherited from GenericTraversableTemplate[(K, V), Iterable]
Inherited from TraversableLike[(K, V), Map[K, V]]
Inherited from GenTraversableLike[(K, V), Map[K, V]]
Inherited from Parallelizable[(K, V), ParMap[K, V]]
Inherited from TraversableOnce[(K, V)]
Inherited from GenTraversableOnce[(K, V)]
Inherited from FilterMonadic[(K, V), Map[K, V]]
Inherited from HasNewBuilder[(K, V), Map[K, V]]
Inherited from Serializable
Inherited from Serializable
Inherited from AnyRef
Inherited from Any
Transactional map that implements the mutable Map interface with an underlying Ref and HashMap.
TransactionalMap and TransactionalVector look like regular mutable datastructures, they even implement the standard Scala 'Map' and 'IndexedSeq' interfaces, but they are implemented using persistent datastructures and managed references under the hood. Therefore they are safe to use in a concurrent environment through the STM. Underlying TransactionalMap is HashMap, an immutable Map but with near constant time access and modification operations.
From Scala you can use TMap as a shorter alias for TransactionalMap.