Movatterモバイル変換


[0]ホーム

URL:


Scala 3
3.7.4
LearnInstallPlaygroundFind A LibraryCommunityBlog
Scala 3
LearnInstallPlaygroundFind A LibraryCommunityBlog
DocsAPI
Generated with
Copyright (c) 2002-2025, LAMP/EPFL
Copyright (c) 2002-2025, LAMP/EPFL
Scala 3/scala/scala.collection/scala.collection.mutable

scala.collection.mutable

Members list

Type members

Classlikes

abstractclassAbstractBuffer[A] extendsAbstractSeq[A],Buffer[A]

Explicit instantiation of theBuffer trait to reduce class file size in subclasses.

Explicit instantiation of theBuffer trait to reduce class file size in subclasses.

Attributes

Source
Buffer.scala
Supertypes
traitBuffer[A]
traitShrinkable[A]
traitGrowable[A]
traitClearable
classAbstractSeq[A]
traitSeq[A]
traitSeqOps[A,Buffer,Buffer[A]]
traitCloneable[Buffer[A]]
traitCloneable
traitIterable[A]
classAbstractSeq[A]
traitSeq[A]
traitEquals
traitSeqOps[A,Buffer,Buffer[A]]
traitInt=>A
traitIterable[A]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
Known subtypes
classArrayBuffer[A]
classArrayDeque[A]
classQueue[A]
classStack[A]
classListBuffer[A]
Show all
abstractclassAbstractIterable[A] extendsAbstractIterable[A],Iterable[A]

Explicit instantiation of theIterable trait to reduce class file size in subclasses.

Explicit instantiation of theIterable trait to reduce class file size in subclasses.

Attributes

Source
Iterable.scala
Supertypes
Known subtypes
classPriorityQueue[A]
abstractclassAbstractMap[K,V] extendsAbstractMap[K,V],Map[K,V]

Explicit instantiation of theMap trait to reduce class file size in subclasses.

Explicit instantiation of theMap trait to reduce class file size in subclasses.

Attributes

Source
Map.scala
Supertypes
traitMap[K,V]
traitMapOps[K,V,Map,Map[K,V]]
traitShrinkable[K]
traitBuilder[(K,V),Map[K,V]]
traitGrowable[(K,V)]
traitClearable
traitCloneable[Map[K,V]]
traitCloneable
traitIterable[(K,V)]
classAbstractMap[K,V]
traitMap[K,V]
traitEquals
traitMapOps[K,V,Map,Map[K,V]]
traitPartialFunction[K,V]
traitK=>V
classAbstractIterable[(K,V)]
traitIterable[(K,V)]
traitIterableOps[(K,V),Iterable,Map[K,V]]
traitIterableOnceOps[(K,V),Iterable,Map[K,V]]
traitIterableOnce[(K,V)]
classObject
traitMatchable
classAny
Show all
Known subtypes
classTrieMap[K,V]
classAnyRefMap[K,V]
classHashMap[K,V]
classLinkedHashMap[K,V]
classListMap[K,V]
classLongMap[V]
classWithDefault[K,V]
classWithDefault[K,V]
classOpenHashMap[Key,Value]
classTreeMap[K,V]
Show all
abstractclassAbstractSeq[A] extendsAbstractSeq[A],Seq[A]

Explicit instantiation of theSeq trait to reduce class file size in subclasses.

Explicit instantiation of theSeq trait to reduce class file size in subclasses.

Attributes

Source
Seq.scala
Supertypes
traitSeq[A]
traitSeqOps[A,Seq,Seq[A]]
traitCloneable[Seq[A]]
traitCloneable
traitIterable[A]
classAbstractSeq[A]
traitSeq[A]
traitEquals
traitSeqOps[A,Seq,Seq[A]]
traitInt=>A
traitIterable[A]
traitIterableOps[A,Seq,Seq[A]]
traitIterableOnceOps[A,Seq,Seq[A]]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
Known subtypes
classArrayBuffer[A]
classArrayDeque[A]
classQueue[A]
classStack[A]
classListBuffer[A]
classArraySeq[T]
classofBoolean
classofByte
classofChar
classofDouble
classofFloat
classofInt
classofLong
classofRef[T]
classofShort
classofUnit
Show all
abstractclassAbstractSet[A] extendsAbstractSet[A],Set[A]

Explicit instantiation of theSet trait to reduce class file size in subclasses.

Explicit instantiation of theSet trait to reduce class file size in subclasses.

Attributes

Source
Set.scala
Supertypes
traitSet[A]
traitSetOps[A,Set,Set[A]]
traitShrinkable[A]
traitBuilder[A,Set[A]]
traitGrowable[A]
traitClearable
traitCloneable[Set[A]]
traitCloneable
traitIterable[A]
classAbstractSet[A]
traitSet[A]
traitEquals
traitSetOps[A,Set,Set[A]]
traitA=>Boolean
traitIterable[A]
traitIterableOps[A,Set,Set[A]]
traitIterableOnceOps[A,Set,Set[A]]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
Known subtypes
classBitSet
classHashSet[A]
classLinkedHashSet[A]
classTreeSet[A]

An implementation of theBuffer class using an array to represent the assembled sequence internally.

An implementation of theBuffer class using an array to represent the assembled sequence internally. Append, update and random access take constant time (amortized time). Prepends and removes are linear in the buffer size.

Type parameters

A

the type of this arraybuffer's elements.

Attributes

See also

"Scala's Collection Library overview" section onArray Buffers for more information.

Companion
object
Source
ArrayBuffer.scala
Supertypes
traitIndexedBuffer[A]
traitIndexedSeq[A]
traitIndexedSeq[A]
traitBuffer[A]
traitShrinkable[A]
traitGrowable[A]
traitClearable
classAbstractSeq[A]
traitSeq[A]
traitCloneable
traitIterable[A]
classAbstractSeq[A]
traitSeq[A]
traitEquals
traitInt=>A
traitIterable[A]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all

Factory object for theArrayBuffer class.

Factory object for theArrayBuffer class.

This object provides a set of operations to createIterable values.

Attributes

Companion
class
Source
ArrayBuffer.scala
Supertypes
Self type

Attributes

Source
ArrayBuffer.scala
Supertypes
traitIndexedSeqOps[A,View,View[A]]
traitSeqView[A]
traitSeqOps[A,View,View[A]]
classAbstractView[A]
traitView[A]
traitIterable[A]
traitIterableOps[A,View,View[A]]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
sealed abstractclassArrayBuilder[T] extendsReusableBuilder[T,Array[T]],Serializable

A builder class for arrays.

A builder class for arrays.

Type parameters

T

the type of the elements for the builder.

Attributes

Companion
object
Source
ArrayBuilder.scala
Supertypes
traitBuilder[T,Array[T]]
traitGrowable[T]
traitClearable
classObject
traitMatchable
classAny
Show all
Known subtypes
classofBoolean
classofByte
classofChar
classofDouble
classofFloat
classofInt
classofLong
classofRef[T]
classofShort
classofUnit
Show all

A companion object for array builders.

A companion object for array builders.

Attributes

Companion
class
Source
ArrayBuilder.scala
Supertypes
classObject
traitMatchable
classAny
Self type

An implementation of a double-ended queue that internally uses a resizable circular buffer.

An implementation of a double-ended queue that internally uses a resizable circular buffer.

Append, prepend, removeHead, removeLast and random-access (indexed-lookup and indexed-replacement) take amortized constant time. In general, removals and insertions at i-th index are O(min(i, n-i)) and thus insertions and removals from end/beginning are fast.

Type parameters

A

the type of this ArrayDeque's elements.

Attributes

Note

Subclassesmust override theofArray protected method to return a more specific type.

Companion
object
Source
ArrayDeque.scala
Supertypes
traitIndexedBuffer[A]
traitIndexedSeq[A]
traitIndexedSeq[A]
traitBuffer[A]
traitShrinkable[A]
traitGrowable[A]
traitClearable
classAbstractSeq[A]
traitSeq[A]
traitCloneable
traitIterable[A]
classAbstractSeq[A]
traitSeq[A]
traitEquals
traitInt=>A
traitIterable[A]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
Known subtypes
classQueue[A]
classStack[A]

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
class
Source
ArrayDeque.scala
Supertypes
Self type
traitArrayDequeOps[A,+CC[_],+C <:AnyRef] extendsStrictOptimizedSeqOps[A,CC,C]

Attributes

Source
ArrayDeque.scala
Supertypes
traitStrictOptimizedSeqOps[A,CC,C]
traitSeqOps[A,CC,C]
traitIterableOps[A,CC,C]
traitIterableOnceOps[A,CC,C]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
Known subtypes
classArrayDeque[A]
classQueue[A]
classStack[A]

A collection representingArray[T].

A collection representingArray[T]. UnlikeArrayBuffer it is always backed by the same underlyingArray, therefore it is not growable or shrinkable.

Type parameters

T

type of the elements in this wrapped array.

Attributes

Companion
object
Source
ArraySeq.scala
Supertypes
Known subtypes
classofBoolean
classofByte
classofChar
classofDouble
classofFloat
classofInt
classofLong
classofRef[T]
classofShort
classofUnit
Show all

A companion object used to create instances ofArraySeq.

A companion object used to create instances ofArraySeq.

Attributes

Companion
class
Source
ArraySeq.scala
Supertypes
Self type

A class for mutable bitsets.

A class for mutable bitsets.

Bitsets are sets of non-negative integers which are represented as variable-size arrays of bits packed into 64-bit words. The lower bound of memory footprint of a bitset is determined by the largest number stored in it.

Attributes

See also

"Scala's Collection Library overview" section onMutable Bitsets for more information.

Companion
object
Source
BitSet.scala
Supertypes
traitBitSet
traitSortedSet[Int]
traitSortedSet[Int]
traitSet[Int]
traitGrowable[Int]
traitClearable
traitCloneable
traitIterable[Int]
traitSet[Int]
traitEquals
traitInt=>Boolean
traitIterable[Int]
classObject
traitMatchable
classAny
Show all

Attributes

Companion
class
Source
BitSet.scala
Supertypes
Self type
BitSet.type

ABuffer is a growable and shrinkableSeq.

ABuffer is a growable and shrinkableSeq.

Attributes

Companion
object
Source
Buffer.scala
Supertypes
traitShrinkable[A]
traitGrowable[A]
traitClearable
traitSeq[A]
traitSeqOps[A,Buffer,Buffer[A]]
traitCloneable[Buffer[A]]
traitCloneable
traitSeq[A]
traitEquals
traitSeqOps[A,Buffer,Buffer[A]]
traitInt=>A
traitIterable[A]
traitIterable[A]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
Known subtypes
classArrayBuffer[A]
classArrayDeque[A]
classQueue[A]
classStack[A]
classListBuffer[A]
traitIndexedBuffer[A]
Show all
objectBuffer extendsDelegate[Buffer]

Attributes

Companion
trait
Source
Buffer.scala
Supertypes
classObject
traitMatchable
classAny
Show all
Self type
Buffer.type
traitBuilder[-A,+To] extendsGrowable[A]

Base trait for collection builders.

Base trait for collection builders.

After callingresult() the behavior of a Builder (which is not also ascala.collection.mutable.ReusableBuilder) is undefined. No further methods should be called. It is common for mutable collections to be their own non-reusable Builder, in which caseresult() simply returnsthis.

Attributes

See also

scala.collection.mutable.ReusableBuilder for Builders which can be reused after callingresult()

Source
Builder.scala
Supertypes
traitGrowable[A]
traitClearable
classObject
traitMatchable
classAny
Known subtypes
classBuilder[K,V]
classGrowableBuilder[Elem,To]
traitMapOps[K,V,CC,C]
classTrieMap[K,V]
classAnyRefMap[K,V]
classHashMap[K,V]
classLinkedHashMap[K,V]
classListMap[K,V]
classLongMap[V]
traitMap[K,V]
traitMap[K,V]
classAbstractMap[K,V]
classWithDefault[K,V]
classWithDefault[K,V]
classOpenHashMap[Key,Value]
classTreeMap[K,V]
traitMultiMap[K,V]
traitSeqMap[K,V]
traitSortedMap[K,V]
traitSortedMapOps[K,V,CC,C]
classPriorityQueue[A]
traitReusableBuilder[Elem,To]
classVectorBuilder[A]
classAnyRefMapBuilder[K,V]
classArrayBuilder[T]
classofBoolean
classofByte
classofChar
classofDouble
classofFloat
classofInt
classofLong
classofRef[T]
classofShort
classofUnit
classImmutableBuilder[A,C]
classListBuffer[A]
traitSetOps[A,CC,C]
classHashSet[A]
classLinkedHashSet[A]
traitSet[A]
classAbstractSet[A]
classBitSet
classTreeSet[A]
traitSortedSet[A]
traitSortedSetOps[A,CC,C]
classAccumulator[A,CC,C]
Show all
Self type
Builder[A,To]

This trait forms part of collections that can be cleared with a clear() call.

This trait forms part of collections that can be cleared with a clear() call.

Attributes

Source
Growable.scala
Supertypes
classObject
traitMatchable
classAny
Known subtypes
traitGrowable[A]
traitBuffer[A]
classArrayBuffer[A]
classArrayDeque[A]
classQueue[A]
classStack[A]
classListBuffer[A]
traitIndexedBuffer[A]
traitBuilder[A,To]
classBuilder[K,V]
classGrowableBuilder[Elem,To]
traitMapOps[K,V,CC,C]
classTrieMap[K,V]
classAnyRefMap[K,V]
classHashMap[K,V]
classLinkedHashMap[K,V]
classListMap[K,V]
classLongMap[V]
traitMap[K,V]
traitMap[K,V]
classAbstractMap[K,V]
classWithDefault[K,V]
classWithDefault[K,V]
classOpenHashMap[Key,Value]
classTreeMap[K,V]
traitMultiMap[K,V]
traitSeqMap[K,V]
traitSortedMap[K,V]
traitSortedMapOps[K,V,CC,C]
classPriorityQueue[A]
traitReusableBuilder[Elem,To]
classVectorBuilder[A]
classAnyRefMapBuilder[K,V]
classArrayBuilder[T]
classofBoolean
classofByte
classofChar
classofDouble
classofFloat
classofInt
classofLong
classofRef[T]
classofShort
classofUnit
classImmutableBuilder[A,C]
traitSetOps[A,CC,C]
classHashSet[A]
classLinkedHashSet[A]
traitSet[A]
classAbstractSet[A]
classBitSet
classTreeSet[A]
traitSortedSet[A]
traitSortedSetOps[A,CC,C]
classAccumulator[A,CC,C]
Show all
traitCloneable[+C <:AnyRef] extendsCloneable

A trait for cloneable collections.

A trait for cloneable collections.

Type parameters

C

Type of the collection, covariant and with reference types as upperbound.

Attributes

Source
Cloneable.scala
Supertypes
traitCloneable
classObject
traitMatchable
classAny
Known subtypes
classArrayDeque[A]
classQueue[A]
classStack[A]
traitMapOps[K,V,CC,C]
classTrieMap[K,V]
classAnyRefMap[K,V]
classHashMap[K,V]
classLinkedHashMap[K,V]
classListMap[K,V]
classLongMap[V]
traitMap[K,V]
traitMap[K,V]
classAbstractMap[K,V]
classWithDefault[K,V]
classWithDefault[K,V]
classOpenHashMap[Key,Value]
classTreeMap[K,V]
traitMultiMap[K,V]
traitSeqMap[K,V]
traitSortedMap[K,V]
traitSortedMapOps[K,V,CC,C]
classPriorityQueue[A]
traitSeqOps[A,CC,C]
traitBuffer[A]
classArrayBuffer[A]
classListBuffer[A]
traitIndexedBuffer[A]
traitIndexedSeqOps[A,CC,C]
classArraySeq[T]
classofBoolean
classofByte
classofChar
classofDouble
classofFloat
classofInt
classofLong
classofRef[T]
classofShort
classofUnit
traitIndexedSeq[T]
traitSeq[A]
classAbstractSeq[A]
classAccumulator[A,CC,C]
traitSetOps[A,CC,C]
classHashSet[A]
classLinkedHashSet[A]
traitSet[A]
classAbstractSet[A]
classBitSet
classTreeSet[A]
traitSortedSet[A]
traitSortedSetOps[A,CC,C]
Show all
finalclassCollisionProofHashMap[K,V](initialCapacity:Int,loadFactor:Double)(implicitordering:Ordering[K]) extendsAbstractMap[K,V],MapOps[K,V,Map,CollisionProofHashMap[K,V]],StrictOptimizedIterableOps[(K,V),Iterable,CollisionProofHashMap[K,V]],StrictOptimizedMapOps[K,V,Map,CollisionProofHashMap[K,V]]

This class implements mutable maps using a hashtable with red-black trees in the buckets for good worst-case performance on hash collisions.

This class implements mutable maps using a hashtable with red-black trees in the buckets for good worst-case performance on hash collisions. AnOrdering is required for the element type. Equality as determined by theOrdering has to be consistent withequals andhashCode. Universal equality of numeric types is not supported (similar toAnyRefMap).

Attributes

See also

"Scala's Collection Library overview" section onHash Tables for more information.

Companion
object
Source
CollisionProofHashMap.scala
Supertypes
classAbstractMap[K,V]
traitMap[K,V]
traitShrinkable[K]
traitBuilder[(K,V),CollisionProofHashMap[K,V]]
traitGrowable[(K,V)]
traitClearable
traitCloneable
traitIterable[(K,V)]
classAbstractMap[K,V]
traitMap[K,V]
traitEquals
traitPartialFunction[K,V]
traitK=>V
classAbstractIterable[(K,V)]
traitIterable[(K,V)]
traitIterableOnce[(K,V)]
classObject
traitMatchable
classAny
Show all

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
class
Source
CollisionProofHashMap.scala
Supertypes
Self type
traitGrowable[-A] extendsClearable

This trait forms part of collections that can be augmented using a+= operator and that can be cleared of all elements using aclear method.

This trait forms part of collections that can be augmented using a+= operator and that can be cleared of all elements using aclear method.

Attributes

Companion
object
Source
Growable.scala
Supertypes
traitClearable
classObject
traitMatchable
classAny
Known subtypes
traitBuffer[A]
classArrayBuffer[A]
classArrayDeque[A]
classQueue[A]
classStack[A]
classListBuffer[A]
traitIndexedBuffer[A]
traitBuilder[A,To]
classBuilder[K,V]
classGrowableBuilder[Elem,To]
traitMapOps[K,V,CC,C]
classTrieMap[K,V]
classAnyRefMap[K,V]
classHashMap[K,V]
classLinkedHashMap[K,V]
classListMap[K,V]
classLongMap[V]
traitMap[K,V]
traitMap[K,V]
classAbstractMap[K,V]
classWithDefault[K,V]
classWithDefault[K,V]
classOpenHashMap[Key,Value]
classTreeMap[K,V]
traitMultiMap[K,V]
traitSeqMap[K,V]
traitSortedMap[K,V]
traitSortedMapOps[K,V,CC,C]
classPriorityQueue[A]
traitReusableBuilder[Elem,To]
classVectorBuilder[A]
classAnyRefMapBuilder[K,V]
classArrayBuilder[T]
classofBoolean
classofByte
classofChar
classofDouble
classofFloat
classofInt
classofLong
classofRef[T]
classofShort
classofUnit
classImmutableBuilder[A,C]
traitSetOps[A,CC,C]
classHashSet[A]
classLinkedHashSet[A]
traitSet[A]
classAbstractSet[A]
classBitSet
classTreeSet[A]
traitSortedSet[A]
traitSortedSetOps[A,CC,C]
classAccumulator[A,CC,C]
Show all
objectGrowable

Attributes

Companion
trait
Source
Growable.scala
Supertypes
classObject
traitMatchable
classAny
Self type
classGrowableBuilder[Elem,To <:Growable[Elem]](valelems:To) extendsBuilder[Elem,To]

The canonical builder for collections that are growable, i.e.

The canonical builder for collections that are growable, i.e. that support an efficient+= method which adds an element to the collection.

GrowableBuilders can produce only a single instance of the collection they are growing.

Attributes

Source
GrowableBuilder.scala
Supertypes
traitBuilder[Elem,To]
traitGrowable[Elem]
traitClearable
classObject
traitMatchable
classAny
Show all

This class implements mutable maps using a hashtable.

This class implements mutable maps using a hashtable.

Type parameters

K

the type of the keys contained in this hash map.

V

the type of the values assigned to keys in this hash map.

Attributes

See also

"Scala's Collection Library overview" section onHash Tables for more information.

Companion
object
Source
HashMap.scala
Supertypes
classAbstractMap[K,V]
traitMap[K,V]
traitMapOps[K,V,HashMap,HashMap[K,V]]
traitShrinkable[K]
traitBuilder[(K,V),HashMap[K,V]]
traitGrowable[(K,V)]
traitClearable
traitCloneable[HashMap[K,V]]
traitCloneable
traitIterable[(K,V)]
classAbstractMap[K,V]
traitMap[K,V]
traitEquals
traitMapOps[K,V,HashMap,HashMap[K,V]]
traitPartialFunction[K,V]
traitK=>V
classAbstractIterable[(K,V)]
traitIterable[(K,V)]
traitIterableOps[(K,V),Iterable,HashMap[K,V]]
traitIterableOnceOps[(K,V),Iterable,HashMap[K,V]]
traitIterableOnce[(K,V)]
classObject
traitMatchable
classAny
Show all
objectHashMap extendsMapFactory[HashMap]

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
class
Source
HashMap.scala
Supertypes
classObject
traitMatchable
classAny
Self type
HashMap.type

This class implements mutable sets using a hashtable.

This class implements mutable sets using a hashtable.

Attributes

See also

"Scala's Collection Library overview" section onHash Tables for more information.

Companion
object
Source
HashSet.scala
Supertypes
classAbstractSet[A]
traitSet[A]
traitSetOps[A,HashSet,HashSet[A]]
traitShrinkable[A]
traitBuilder[A,HashSet[A]]
traitGrowable[A]
traitClearable
traitCloneable[HashSet[A]]
traitCloneable
traitIterable[A]
classAbstractSet[A]
traitSet[A]
traitEquals
traitSetOps[A,HashSet,HashSet[A]]
traitA=>Boolean
traitIterable[A]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
class
Source
HashSet.scala
Supertypes
Self type
HashSet.type
abstractclassImmutableBuilder[-A,C <:IterableOnce[_]](empty:C) extendsReusableBuilder[A,C]

Reusable builder for immutable collections

Reusable builder for immutable collections

Attributes

Source
ImmutableBuilder.scala
Supertypes
traitReusableBuilder[A,C]
traitBuilder[A,C]
traitGrowable[A]
traitClearable
classObject
traitMatchable
classAny
Show all

Attributes

Companion
object
Source
Buffer.scala
Supertypes
Known subtypes
classArrayBuffer[A]
classArrayDeque[A]
classQueue[A]
classStack[A]

Attributes

Companion
trait
Source
Buffer.scala
Supertypes
Self type

Attributes

Companion
object
Source
IndexedSeq.scala
Supertypes
Known subtypes
classArraySeq[T]
classofBoolean
classofByte
classofChar
classofDouble
classofFloat
classofInt
classofLong
classofRef[T]
classofShort
classofUnit
traitIndexedBuffer[A]
classArrayBuffer[A]
classArrayDeque[A]
classQueue[A]
classStack[A]
Show all

Attributes

Companion
trait
Source
IndexedSeq.scala
Supertypes
Self type
traitIndexedSeqOps[A,+CC[_],+C <:AnyRef] extendsIndexedSeqOps[A,CC,C],SeqOps[A,CC,C]

Attributes

Source
IndexedSeq.scala
Supertypes
traitSeqOps[A,CC,C]
traitCloneable[C]
traitCloneable
traitIndexedSeqOps[A,CC,C]
traitSeqOps[A,CC,C]
traitIterableOps[A,CC,C]
traitIterableOnceOps[A,CC,C]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
Known subtypes
classArrayBuffer[A]
classArrayDeque[A]
classQueue[A]
classStack[A]
classArraySeq[T]
classofBoolean
classofByte
classofChar
classofDouble
classofFloat
classofInt
classofLong
classofRef[T]
classofShort
classofUnit
traitIndexedBuffer[A]
traitIndexedSeq[T]
Show all

Attributes

Companion
object
Source
Iterable.scala
Supertypes
Known subtypes
classPriorityQueue[A]
traitMap[K,V]
traitMap[K,V]
classTrieMap[K,V]
classAbstractMap[K,V]
classAnyRefMap[K,V]
classHashMap[K,V]
classLinkedHashMap[K,V]
classListMap[K,V]
classLongMap[V]
classWithDefault[K,V]
classWithDefault[K,V]
classOpenHashMap[Key,Value]
classTreeMap[K,V]
traitMultiMap[K,V]
traitSeqMap[K,V]
traitSortedMap[K,V]
traitSeq[A]
classAbstractSeq[A]
classArrayBuffer[A]
classArrayDeque[A]
classQueue[A]
classStack[A]
classListBuffer[A]
classArraySeq[T]
classofBoolean
classofByte
classofChar
classofDouble
classofFloat
classofInt
classofLong
classofRef[T]
classofShort
classofUnit
traitBuffer[A]
traitIndexedBuffer[A]
traitIndexedSeq[T]
classAccumulator[A,CC,C]
traitSet[A]
classAbstractSet[A]
classBitSet
classHashSet[A]
classLinkedHashSet[A]
classTreeSet[A]
traitSortedSet[A]
Show all
objectIterable extendsDelegate[Iterable]

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
trait
Source
Iterable.scala
Supertypes
classObject
traitMatchable
classAny
Show all
Self type

This class implements mutable maps using a hashtable.

This class implements mutable maps using a hashtable. The iterator and all traversal methods of this class visit elements in the order they were inserted.

Type parameters

K

the type of the keys contained in this hash map.

V

the type of the values assigned to keys in this hash map.

Attributes

Companion
object
Source
LinkedHashMap.scala
Supertypes
traitSeqMap[K,V]
traitSeqMap[K,V]
classAbstractMap[K,V]
traitMap[K,V]
traitShrinkable[K]
traitBuilder[(K,V),LinkedHashMap[K,V]]
traitGrowable[(K,V)]
traitClearable
traitCloneable
traitIterable[(K,V)]
classAbstractMap[K,V]
traitMap[K,V]
traitEquals
traitPartialFunction[K,V]
traitK=>V
classAbstractIterable[(K,V)]
traitIterable[(K,V)]
traitIterableOnce[(K,V)]
classObject
traitMatchable
classAny
Show all

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
class
Source
LinkedHashMap.scala
Supertypes
Self type

This class implements mutable sets using a hashtable.

This class implements mutable sets using a hashtable. The iterator and all traversal methods of this class visit elements in the order they were inserted.

Type parameters

A

the type of the elements contained in this set.

Attributes

Companion
object
Source
LinkedHashSet.scala
Supertypes

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
class
Source
LinkedHashSet.scala
Supertypes
Self type

ABuffer implementation backed by a list.

ABuffer implementation backed by a list. It provides constant time prepend and append. Most other operations are linear.

Type parameters

A

the type of this list buffer's elements.

Attributes

See also

"Scala's Collection Library overview" section onList Buffers for more information.

Companion
object
Source
ListBuffer.scala
Supertypes
traitReusableBuilder[A,List[A]]
traitBuilder[A,List[A]]
traitBuffer[A]
traitShrinkable[A]
traitGrowable[A]
traitClearable
classAbstractSeq[A]
traitSeq[A]
traitCloneable
traitIterable[A]
classAbstractSeq[A]
traitSeq[A]
traitEquals
traitInt=>A
traitIterable[A]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all

Attributes

Companion
class
Source
ListBuffer.scala
Supertypes
Self type

This class implements mutable maps withLong keys based on a hash table with open addressing.

This class implements mutable maps withLong keys based on a hash table with open addressing.

Basic map operations on single entries, includingcontains andget, are typically substantially faster withLongMap thanHashMap. Methods that act on the whole map, includingforeach andmap are not in general expected to be faster than with a generic map, save for those that take particular advantage of the internal structure of the map:foreachKey,foreachValue,mapValuesNow, andtransformValues.

Maps with open addressing may become less efficient at lookup after repeated addition/removal of elements. AlthoughLongMap makes a decent attempt to remain efficient regardless, callingrepack on a map that will no longer have elements removed but will be used heavily may save both time and storage space.

This map is not intended to contain more than 229 entries (approximately 500 million). The maximum capacity is 230, but performance will degrade rapidly as 2^30 is approached.

Attributes

Companion
object
Source
LongMap.scala
Supertypes
classAbstractMap[Long,V]
traitMap[Long,V]
traitMapOps[Long,V,Map,LongMap[V]]
traitBuilder[(Long,V),LongMap[V]]
traitGrowable[(Long,V)]
traitClearable
traitCloneable[LongMap[V]]
traitCloneable
traitIterable[(Long,V)]
classAbstractMap[Long,V]
traitMap[Long,V]
traitEquals
traitMapOps[Long,V,Map,LongMap[V]]
traitLong=>V
traitIterable[(Long,V)]
traitIterableOnce[(Long,V)]
classObject
traitMatchable
classAny
Show all
objectLongMap

Attributes

Companion
class
Source
LongMap.scala
Supertypes
classObject
traitMatchable
classAny
Self type
LongMap.type
traitMap[K,V] extendsIterable[(K,V)],Map[K,V],MapOps[K,V,Map,Map[K,V]],Growable[(K,V)],Shrinkable[K],MapFactoryDefaults[K,V,Map,Iterable]

Base type of mutable Maps

Base type of mutable Maps

Attributes

Companion
object
Source
Map.scala
Supertypes
traitMapOps[K,V,Map,Map[K,V]]
traitShrinkable[K]
traitBuilder[(K,V),Map[K,V]]
traitGrowable[(K,V)]
traitClearable
traitCloneable[Map[K,V]]
traitCloneable
traitMap[K,V]
traitEquals
traitMapOps[K,V,Map,Map[K,V]]
traitPartialFunction[K,V]
traitK=>V
traitIterable[(K,V)]
traitIterable[(K,V)]
traitIterableOps[(K,V),Iterable,Map[K,V]]
traitIterableOnceOps[(K,V),Iterable,Map[K,V]]
traitIterableOnce[(K,V)]
classObject
traitMatchable
classAny
Show all
Known subtypes
traitMap[K,V]
classTrieMap[K,V]
classAbstractMap[K,V]
classAnyRefMap[K,V]
classHashMap[K,V]
classLinkedHashMap[K,V]
classListMap[K,V]
classLongMap[V]
classWithDefault[K,V]
classWithDefault[K,V]
classOpenHashMap[Key,Value]
classTreeMap[K,V]
traitMultiMap[K,V]
traitSeqMap[K,V]
traitSortedMap[K,V]
Show all
objectMap extendsDelegate[Map]

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
trait
Source
Map.scala
Supertypes
classDelegate[Map]
classObject
traitMatchable
classAny
Show all
Self type
Map.type
traitMapOps[K,V,+CC <:([X,Y] =>>MapOps[X,Y,CC,_]),+C <:MapOps[K,V,CC,C]] extendsIterableOps[(K,V),Iterable,C],MapOps[K,V,CC,C],Cloneable[C],Builder[(K,V),C],Growable[(K,V)],Shrinkable[K]

Attributes

Source
Map.scala
Supertypes
traitShrinkable[K]
traitBuilder[(K,V),C]
traitGrowable[(K,V)]
traitClearable
traitCloneable[C]
traitCloneable
traitMapOps[K,V,CC,C]
traitPartialFunction[K,V]
traitK=>V
traitIterableOps[(K,V),Iterable,C]
traitIterableOnceOps[(K,V),Iterable,C]
traitIterableOnce[(K,V)]
classObject
traitMatchable
classAny
Show all
Known subtypes
classTrieMap[K,V]
classAnyRefMap[K,V]
classHashMap[K,V]
classLinkedHashMap[K,V]
classListMap[K,V]
classLongMap[V]
traitMap[K,V]
traitMap[K,V]
classAbstractMap[K,V]
classWithDefault[K,V]
classWithDefault[K,V]
classOpenHashMap[Key,Value]
classTreeMap[K,V]
traitMultiMap[K,V]
traitSeqMap[K,V]
traitSortedMap[K,V]
traitSortedMapOps[K,V,CC,C]
Show all

A heap-based priority queue.

A heap-based priority queue.

To prioritize elements of typeA there must be an implicitOrdering[A] available at creation. Elements are retrieved in priority order by usingdequeue ordequeueAll.

If multiple elements have the same priority as determined by the ordering for thisPriorityQueue, no guarantees are made regarding the order in which those elements are returned bydequeue ordequeueAll. In particular, that means this class does not guarantee first-in-first-out behavior, as may be incorrectly inferred from the fact that this data structure is called a "queue".

Only thedequeue anddequeueAll methods will return elements in priority order (while removing elements from the heap). Standard collection methods such asdrop,iterator,toList andtoString use an arbitrary iteration order: they will traverse the heap or remove elements in whichever order seems most convenient.

Therefore, printing aPriorityQueue will not show elements in priority order, though the highest-priority element will be printed first. To print the elements in order, it's necessary todequeue them. To do this non-destructively, duplicate thePriorityQueue first; theclone method is a suitable way to obtain a disposable copy.

Client keys are assumed to be immutable. Mutating keys may violate the invariant of the underlying heap-ordered tree. Note thatclone does not rebuild the underlying tree.

scala> val pq = collection.mutable.PriorityQueue(1, 2, 5, 3, 7)val pq: scala.collection.mutable.PriorityQueue[Int] = PriorityQueue(7, 3, 5, 1, 2)scala> pq.toList              // also not in orderval res0: List[Int] = List(7, 3, 5, 1, 2)scala> pq.clone.dequeueAllval res1: Seq[Int] = ArraySeq(7, 5, 3, 2, 1)

Type parameters

A

type of the elements in this priority queue.

Value parameters

ord

implicit ordering used to compare the elements of typeA.

Attributes

Companion
object
Source
PriorityQueue.scala
Supertypes

Queue objects implement data structures that allow to insert and retrieve elements in a first-in-first-out (FIFO) manner.

Queue objects implement data structures that allow to insert and retrieve elements in a first-in-first-out (FIFO) manner.

Attributes

Companion
object
Source
Queue.scala
Supertypes
classArrayDeque[A]
traitIndexedBuffer[A]
traitIndexedSeq[A]
traitIndexedSeq[A]
traitBuffer[A]
traitShrinkable[A]
traitGrowable[A]
traitClearable
classAbstractSeq[A]
traitSeq[A]
traitSeqOps[A,Queue,Queue[A]]
traitCloneable[Queue[A]]
traitCloneable
traitIterable[A]
classAbstractSeq[A]
traitSeq[A]
traitEquals
traitSeqOps[A,Queue,Queue[A]]
traitInt=>A
traitIterable[A]
traitIterableOps[A,Queue,Queue[A]]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
class
Source
Queue.scala
Supertypes
Self type
Queue.type
traitReusableBuilder[-Elem,+To] extendsBuilder[Elem,To]

ReusableBuilder is a marker trait that indicates that aBuilder can be reused to build more than one instance of a collection.

ReusableBuilder is a marker trait that indicates that aBuilder can be reused to build more than one instance of a collection. In particular, callingresult() followed byclear() will produce a collection and reset the builder to begin building a new collection of the same type.

In general no method other thanclear() may be called afterresult(). It is up to subclasses to implement and to document other allowed sequences of operations (e.g. calling other methods afterresult() in order to obtain different snapshots of a collection under construction).

Type parameters

Elem

the type of elements that get added to the builder.

To

the type of collection that it produced.

Attributes

Source
ReusableBuilder.scala
Supertypes
traitBuilder[Elem,To]
traitGrowable[Elem]
traitClearable
classObject
traitMatchable
classAny
Show all
Known subtypes
classVectorBuilder[A]
classAnyRefMapBuilder[K,V]
classArrayBuilder[T]
classofBoolean
classofByte
classofChar
classofDouble
classofFloat
classofInt
classofLong
classofRef[T]
classofShort
classofUnit
classImmutableBuilder[A,C]
classListBuffer[A]
Show all
traitSeq[A] extendsIterable[A],Seq[A],SeqOps[A,Seq,Seq[A]],IterableFactoryDefaults[A,Seq]

Attributes

Companion
object
Source
Seq.scala
Supertypes
traitSeqOps[A,Seq,Seq[A]]
traitCloneable[Seq[A]]
traitCloneable
traitSeq[A]
traitEquals
traitSeqOps[A,Seq,Seq[A]]
traitInt=>A
traitIterable[A]
traitIterable[A]
traitIterableOps[A,Seq,Seq[A]]
traitIterableOnceOps[A,Seq,Seq[A]]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
Known subtypes
classAbstractSeq[A]
classArrayBuffer[A]
classArrayDeque[A]
classQueue[A]
classStack[A]
classListBuffer[A]
classArraySeq[T]
classofBoolean
classofByte
classofChar
classofDouble
classofFloat
classofInt
classofLong
classofRef[T]
classofShort
classofUnit
traitBuffer[A]
traitIndexedBuffer[A]
traitIndexedSeq[T]
classAccumulator[A,CC,C]
Show all
objectSeq extendsDelegate[Seq]

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
trait
Source
Seq.scala
Supertypes
classDelegate[Seq]
classObject
traitMatchable
classAny
Show all
Self type
Seq.type
traitSeqMap[K,V] extendsMap[K,V],SeqMap[K,V],MapOps[K,V,SeqMap,SeqMap[K,V]],MapFactoryDefaults[K,V,SeqMap,Iterable]

A generic trait for ordered mutable maps.

A generic trait for ordered mutable maps. Concrete classes have to provide functionality for the abstract methods inSeqMap.

Note that when checking for equalitySeqMap does not take into account ordering.

Type parameters

K

the type of the keys contained in this linked map.

V

the type of the values associated with the keys in this linked map.

Attributes

Companion
object
Source
SeqMap.scala
Supertypes
traitSeqMap[K,V]
traitMap[K,V]
traitMapOps[K,V,SeqMap,SeqMap[K,V]]
traitShrinkable[K]
traitBuilder[(K,V),SeqMap[K,V]]
traitGrowable[(K,V)]
traitClearable
traitCloneable[SeqMap[K,V]]
traitCloneable
traitMap[K,V]
traitEquals
traitMapOps[K,V,SeqMap,SeqMap[K,V]]
traitPartialFunction[K,V]
traitK=>V
traitIterable[(K,V)]
traitIterable[(K,V)]
traitIterableOps[(K,V),Iterable,SeqMap[K,V]]
traitIterableOnceOps[(K,V),Iterable,SeqMap[K,V]]
traitIterableOnce[(K,V)]
classObject
traitMatchable
classAny
Show all
Known subtypes
classLinkedHashMap[K,V]
objectSeqMap extendsDelegate[SeqMap]

Attributes

Companion
trait
Source
SeqMap.scala
Supertypes
classObject
traitMatchable
classAny
Show all
Self type
SeqMap.type
traitSeqOps[A,+CC[_],+C <:AnyRef] extendsSeqOps[A,CC,C],Cloneable[C]

Attributes

Source
Seq.scala
Supertypes
traitCloneable[C]
traitCloneable
traitSeqOps[A,CC,C]
traitIterableOps[A,CC,C]
traitIterableOnceOps[A,CC,C]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
Known subtypes
traitBuffer[A]
classArrayBuffer[A]
classArrayDeque[A]
classQueue[A]
classStack[A]
classListBuffer[A]
traitIndexedBuffer[A]
traitIndexedSeqOps[A,CC,C]
classArraySeq[T]
classofBoolean
classofByte
classofChar
classofDouble
classofFloat
classofInt
classofLong
classofRef[T]
classofShort
classofUnit
traitIndexedSeq[T]
traitSeq[A]
classAbstractSeq[A]
classAccumulator[A,CC,C]
Show all
traitSet[A] extendsIterable[A],Set[A],SetOps[A,Set,Set[A]],IterableFactoryDefaults[A,Set]

Base trait for mutable sets

Base trait for mutable sets

Attributes

Companion
object
Source
Set.scala
Supertypes
traitSetOps[A,Set,Set[A]]
traitShrinkable[A]
traitBuilder[A,Set[A]]
traitGrowable[A]
traitClearable
traitCloneable[Set[A]]
traitCloneable
traitSet[A]
traitEquals
traitSetOps[A,Set,Set[A]]
traitA=>Boolean
traitIterable[A]
traitIterable[A]
traitIterableOps[A,Set,Set[A]]
traitIterableOnceOps[A,Set,Set[A]]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
Known subtypes
classAbstractSet[A]
classBitSet
classHashSet[A]
classLinkedHashSet[A]
classTreeSet[A]
traitSortedSet[A]
Show all
objectSet extendsDelegate[Set]

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
trait
Source
Set.scala
Supertypes
classDelegate[Set]
classObject
traitMatchable
classAny
Show all
Self type
Set.type
traitSetOps[A,+CC[X],+C <:SetOps[A,CC,C]] extendsSetOps[A,CC,C],IterableOps[A,CC,C],Cloneable[C],Builder[A,C],Growable[A],Shrinkable[A]

Attributes

Source
Set.scala
Supertypes
traitShrinkable[A]
traitBuilder[A,C]
traitGrowable[A]
traitClearable
traitCloneable[C]
traitCloneable
traitSetOps[A,CC,C]
traitA=>Boolean
traitIterableOps[A,CC,C]
traitIterableOnceOps[A,CC,C]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
Known subtypes
classHashSet[A]
classLinkedHashSet[A]
traitSet[A]
classAbstractSet[A]
classBitSet
classTreeSet[A]
traitSortedSet[A]
traitSortedSetOps[A,CC,C]
Show all
traitShrinkable[-A]

This trait forms part of collections that can be reduced using a-= operator.

This trait forms part of collections that can be reduced using a-= operator.

Attributes

Source
Shrinkable.scala
Supertypes
classObject
traitMatchable
classAny
Known subtypes
traitBuffer[A]
classArrayBuffer[A]
classArrayDeque[A]
classQueue[A]
classStack[A]
classListBuffer[A]
traitIndexedBuffer[A]
traitMap[K,V]
traitMap[K,V]
classTrieMap[K,V]
classAbstractMap[K,V]
classAnyRefMap[K,V]
classHashMap[K,V]
classLinkedHashMap[K,V]
classListMap[K,V]
classLongMap[V]
classWithDefault[K,V]
classWithDefault[K,V]
classOpenHashMap[Key,Value]
classTreeMap[K,V]
traitMultiMap[K,V]
traitSeqMap[K,V]
traitSortedMap[K,V]
traitMapOps[K,V,CC,C]
traitSortedMapOps[K,V,CC,C]
traitSetOps[A,CC,C]
classHashSet[A]
classLinkedHashSet[A]
traitSet[A]
classAbstractSet[A]
classBitSet
classTreeSet[A]
traitSortedSet[A]
traitSortedSetOps[A,CC,C]
Show all

Base type for mutable sorted map collections

Base type for mutable sorted map collections

Attributes

Companion
object
Source
SortedMap.scala
Supertypes
traitMap[K,V]
traitMapOps[K,V,Map,SortedMap[K,V]]
traitShrinkable[K]
traitBuilder[(K,V),SortedMap[K,V]]
traitGrowable[(K,V)]
traitClearable
traitCloneable[SortedMap[K,V]]
traitCloneable
traitIterable[(K,V)]
traitSortedMap[K,V]
traitSortedOps[K,SortedMap[K,V]]
traitMap[K,V]
traitEquals
traitMapOps[K,V,Map,SortedMap[K,V]]
traitPartialFunction[K,V]
traitK=>V
traitIterable[(K,V)]
traitIterableOps[(K,V),Iterable,SortedMap[K,V]]
traitIterableOnce[(K,V)]
classObject
traitMatchable
classAny
Show all
Known subtypes
classWithDefault[K,V]
classTreeMap[K,V]

Attributes

Companion
trait
Source
SortedMap.scala
Supertypes
classObject
traitMatchable
classAny
Show all
Self type
traitSortedMapOps[K,V,+CC <:([X,Y] =>>Map[X,Y] &SortedMapOps[X,Y,CC,_]),+C <:SortedMapOps[K,V,CC,C]] extendsSortedMapOps[K,V,CC,C],MapOps[K,V,Map,C]

Attributes

Source
SortedMap.scala
Supertypes
traitMapOps[K,V,Map,C]
traitShrinkable[K]
traitBuilder[(K,V),C]
traitGrowable[(K,V)]
traitClearable
traitCloneable[C]
traitCloneable
traitSortedMapOps[K,V,CC,C]
traitSortedOps[K,C]
traitMapOps[K,V,Map,C]
traitPartialFunction[K,V]
traitK=>V
traitIterableOps[(K,V),Iterable,C]
traitIterableOnceOps[(K,V),Iterable,C]
traitIterableOnce[(K,V)]
classObject
traitMatchable
classAny
Show all
Known subtypes
traitSortedMap[K,V]
classWithDefault[K,V]
classTreeMap[K,V]

Base type for mutable sorted set collections

Base type for mutable sorted set collections

Attributes

Companion
object
Source
SortedSet.scala
Supertypes
traitSortedSet[A]
traitSortedOps[A,SortedSet[A]]
traitSet[A]
traitSetOps[A,Set,SortedSet[A]]
traitShrinkable[A]
traitBuilder[A,SortedSet[A]]
traitGrowable[A]
traitClearable
traitCloneable
traitSet[A]
traitEquals
traitSetOps[A,Set,SortedSet[A]]
traitA=>Boolean
traitIterable[A]
traitIterable[A]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
Known subtypes
classBitSet
classTreeSet[A]

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
trait
Source
SortedSet.scala
Supertypes
Self type
traitSortedSetOps[A,+CC <:(SortedSet),+C <:SortedSetOps[A,CC,C]] extendsSetOps[A,Set,C],SortedSetOps[A,CC,C]

Attributes

Source
SortedSet.scala
Supertypes
traitSortedSetOps[A,CC,C]
traitSortedOps[A,C]
traitSetOps[A,Set,C]
traitShrinkable[A]
traitBuilder[A,C]
traitGrowable[A]
traitClearable
traitCloneable[C]
traitCloneable
traitSetOps[A,Set,C]
traitA=>Boolean
traitIterableOps[A,Set,C]
traitIterableOnceOps[A,Set,C]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all
Known subtypes
classBitSet
traitSortedSet[A]
classTreeSet[A]

A stack implements a data structure which allows to store and retrieve objects in a last-in-first-out (LIFO) fashion.

A stack implements a data structure which allows to store and retrieve objects in a last-in-first-out (LIFO) fashion.

Note that operations which consume and produce iterables preserve order, rather than reversing it (as would be expected from building a new stack by pushing an element at a time).

Type parameters

A

type of the elements contained in this stack.

Attributes

Companion
object
Source
Stack.scala
Supertypes
classArrayDeque[A]
traitIndexedBuffer[A]
traitIndexedSeq[A]
traitIndexedSeq[A]
traitBuffer[A]
traitShrinkable[A]
traitGrowable[A]
traitClearable
classAbstractSeq[A]
traitSeq[A]
traitSeqOps[A,Stack,Stack[A]]
traitCloneable[Stack[A]]
traitCloneable
traitIterable[A]
classAbstractSeq[A]
traitSeq[A]
traitEquals
traitSeqOps[A,Stack,Stack[A]]
traitInt=>A
traitIterable[A]
traitIterableOps[A,Stack,Stack[A]]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
class
Source
Stack.scala
Supertypes
Self type
Stack.type

A builder ofString which is also a mutable sequence of characters.

A builder ofString which is also a mutable sequence of characters.

This class provides an API mostly compatible withjava.lang.StringBuilder, except where there are conflicts with the Scala collections API, such as thereverse method:reverse produces a newStringBuilder, andreverseInPlace mutates this builder.

Mutating operations return eitherthis.type, i.e., the current builder, orUnit.

Other methods extract data or information from the builder without mutating it.

The distinction is also reflected in naming conventions used by collections, such asappend, which mutates, andappended, which does not, orreverse, which does not mutate, andreverseInPlace, which does.

TheString result may be obtained using eitherresult() ortoString.

This Builder can be reused after callingresult() without an intermediate call toclear() in order to build multiple related results.

Attributes

See also

"Scala's Collection Library overview" section onStringBuilders for more information.

Companion
object
Source
StringBuilder.scala
Supertypes
traitGrowable[Char]
traitClearable
traitSeq[Char]
traitCloneable
traitIterable[Char]
traitSeq[Char]
traitEquals
traitInt=>Char
traitIterable[Char]
classObject
traitMatchable
classAny
Show all

Attributes

Companion
class
Source
StringBuilder.scala
Supertypes
classObject
traitMatchable
classAny
Self type

A mutable sorted map implemented using a mutable red-black tree as underlying data structure.

A mutable sorted map implemented using a mutable red-black tree as underlying data structure.

Type parameters

K

the type of the keys contained in this tree map.

V

the type of the values associated with the keys.

Value parameters

ordering

the implicit ordering used to compare objects of typeA.

Attributes

Companion
object
Source
TreeMap.scala
Supertypes
traitSortedMap[K,V]
traitSortedMapOps[K,V,TreeMap,TreeMap[K,V]]
traitSortedMap[K,V]
traitSortedMapOps[K,V,TreeMap,TreeMap[K,V]]
traitSortedOps[K,TreeMap[K,V]]
classAbstractMap[K,V]
traitMap[K,V]
traitMapOps[K,V,Map,TreeMap[K,V]]
traitShrinkable[K]
traitBuilder[(K,V),TreeMap[K,V]]
traitGrowable[(K,V)]
traitClearable
traitCloneable[TreeMap[K,V]]
traitCloneable
traitIterable[(K,V)]
classAbstractMap[K,V]
traitMap[K,V]
traitEquals
traitMapOps[K,V,Map,TreeMap[K,V]]
traitPartialFunction[K,V]
traitK=>V
classAbstractIterable[(K,V)]
traitIterable[(K,V)]
traitIterableOps[(K,V),Iterable,TreeMap[K,V]]
traitIterableOnceOps[(K,V),Iterable,TreeMap[K,V]]
traitIterableOnce[(K,V)]
classObject
traitMatchable
classAny
Show all

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
class
Source
TreeMap.scala
Supertypes
Self type
TreeMap.type

A mutable sorted set implemented using a mutable red-black tree as underlying data structure.

A mutable sorted set implemented using a mutable red-black tree as underlying data structure.

Type parameters

A

the type of the keys contained in this tree set.

Value parameters

ordering

the implicit ordering used to compare objects of typeA.

Attributes

Companion
object
Source
TreeSet.scala
Supertypes
traitSortedSet[A]
traitSortedSet[A]
traitSortedOps[A,TreeSet[A]]
classAbstractSet[A]
traitSet[A]
traitSetOps[A,Set,TreeSet[A]]
traitShrinkable[A]
traitBuilder[A,TreeSet[A]]
traitGrowable[A]
traitClearable
traitCloneable[TreeSet[A]]
traitCloneable
traitIterable[A]
classAbstractSet[A]
traitSet[A]
traitEquals
traitSetOps[A,Set,TreeSet[A]]
traitA=>Boolean
traitIterable[A]
traitIterableOps[A,Set,TreeSet[A]]
traitIterableOnce[A]
classObject
traitMatchable
classAny
Show all

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
class
Source
TreeSet.scala
Supertypes
Self type
TreeSet.type

A buffer that stores elements in an unrolled linked list.

A buffer that stores elements in an unrolled linked list.

Unrolled linked lists store elements in linked fixed size arrays.

Unrolled buffers retain locality and low memory overhead properties of array buffers, but offer much more efficient element addition, since they never reallocate and copy the internal array.

However, they provideO(n/m) complexity random access, wheren is the number of elements, andm the size of internal array chunks.

Ideal to use when: - elements are added to the buffer and then all of the elements are traversed sequentially - two unrolled buffers need to be concatenated (seeconcat)

Better than singly linked lists for random access, but should still be avoided for such a purpose.

Attributes

Companion
object
Source
UnrolledBuffer.scala
Supertypes
traitBuffer[T]
traitShrinkable[T]
traitGrowable[T]
traitClearable
classAbstractSeq[T]
traitSeq[T]
traitCloneable
traitIterable[T]
classAbstractSeq[T]
traitSeq[T]
traitEquals
traitInt=>T
traitIterable[T]
traitIterableOnce[T]
classObject
traitMatchable
classAny
Show all
classWeakHashMap[K,V] extendsJMapWrapper[K,V],JMapWrapperLike[K,V,WeakHashMap,WeakHashMap[K,V]],MapFactoryDefaults[K,V,WeakHashMap,Iterable]

A hash map with references to entries which are weakly reachable.

A hash map with references to entries which are weakly reachable. Entries are removed from this map when the key is no longer (strongly) referenced. This class wrapsjava.util.WeakHashMap.

Type parameters

K

type of keys contained in this map

V

type of values associated with the keys

Attributes

See also

"Scala's Collection Library overview" section onWeak Hash Maps for more information.

Companion
object
Source
WeakHashMap.scala
Supertypes
classJMapWrapper[K,V]
classAbstractJMapWrapper[K,V]
traitJMapWrapperLike[K,V,WeakHashMap,WeakHashMap[K,V]]
classAbstractMap[K,V]
traitMap[K,V]
traitShrinkable[K]
traitBuilder[(K,V),WeakHashMap[K,V]]
traitGrowable[(K,V)]
traitClearable
traitCloneable
traitIterable[(K,V)]
classAbstractMap[K,V]
traitMap[K,V]
traitEquals
traitPartialFunction[K,V]
traitK=>V
classAbstractIterable[(K,V)]
traitIterable[(K,V)]
traitIterableOps[(K,V),Iterable,WeakHashMap[K,V]]
traitIterableOnce[(K,V)]
classObject
traitMatchable
classAny
Show all

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
class
Source
WeakHashMap.scala
Supertypes
Self type

Deprecated classlikes

This class implements mutable maps withAnyRef keys based on a hash table with open addressing.

This class implements mutable maps withAnyRef keys based on a hash table with open addressing.

Basic map operations on single entries, includingcontains andget, are typically significantly faster withAnyRefMap thanHashMap. Note that numbers and characters are not handled specially in AnyRefMap; only plainequals andhashCode are used in comparisons.

Methods that traverse or regenerate the map, includingforeach andmap, are not in general faster than withHashMap. The methodsforeachKey,foreachValue,mapValuesNow, andtransformValues are, however, faster than alternative ways to achieve the same functionality.

Maps with open addressing may become less efficient at lookup after repeated addition/removal of elements. AlthoughAnyRefMap makes a decent attempt to remain efficient regardless, callingrepack on a map that will no longer have elements removed but will be used heavily may save both time and storage space.

This map is not intended to contain more than 229 entries (approximately 500 million). The maximum capacity is 230, but performance will degrade rapidly as 230 is approached.

Attributes

Companion
object
Deprecated
[Since version 2.13.16]Use `scala.collection.mutable.HashMap` instead for better performance.
Source
AnyRefMap.scala
Supertypes
classAbstractMap[K,V]
traitMap[K,V]
traitMapOps[K,V,Map,AnyRefMap[K,V]]
traitShrinkable[K]
traitBuilder[(K,V),AnyRefMap[K,V]]
traitGrowable[(K,V)]
traitClearable
traitCloneable[AnyRefMap[K,V]]
traitCloneable
traitIterable[(K,V)]
classAbstractMap[K,V]
traitMap[K,V]
traitEquals
traitMapOps[K,V,Map,AnyRefMap[K,V]]
traitPartialFunction[K,V]
traitK=>V
classAbstractIterable[(K,V)]
traitIterable[(K,V)]
traitIterableOps[(K,V),Iterable,AnyRefMap[K,V]]
traitIterableOnce[(K,V)]
classObject
traitMatchable
classAny
Show all
objectAnyRefMap

Attributes

Companion
class
Deprecated
[Since version 2.13.16]Use `scala.collection.mutable.HashMap` instead for better performance.
Source
AnyRefMap.scala
Supertypes
classObject
traitMatchable
classAny
Self type

A simple mutable map backed by a list, so it preserves insertion order.

A simple mutable map backed by a list, so it preserves insertion order.

Type parameters

K

the type of the keys contained in this list map.

V

the type of the values assigned to keys in this list map.

Attributes

Companion
object
Deprecated
[Since version 2.13.0]Use an immutable.ListMap assigned to a var instead of mutable.ListMap
Source
ListMap.scala
Supertypes
classAbstractMap[K,V]
traitMap[K,V]
traitMapOps[K,V,ListMap,ListMap[K,V]]
traitShrinkable[K]
traitBuilder[(K,V),ListMap[K,V]]
traitGrowable[(K,V)]
traitClearable
traitCloneable[ListMap[K,V]]
traitCloneable
traitIterable[(K,V)]
classAbstractMap[K,V]
traitMap[K,V]
traitEquals
traitMapOps[K,V,ListMap,ListMap[K,V]]
traitPartialFunction[K,V]
traitK=>V
classAbstractIterable[(K,V)]
traitIterable[(K,V)]
traitIterableOps[(K,V),Iterable,ListMap[K,V]]
traitIterableOnceOps[(K,V),Iterable,ListMap[K,V]]
traitIterableOnce[(K,V)]
classObject
traitMatchable
classAny
Show all
objectListMap extendsMapFactory[ListMap]

This object provides a set of operations to createIterable values.

This object provides a set of operations to createIterable values.

Attributes

Companion
class
Deprecated
[Since version 2.13.0]Use an immutable.ListMap assigned to a var instead of mutable.ListMap
Source
ListMap.scala
Supertypes
classObject
traitMatchable
classAny
Self type
ListMap.type
traitMultiMap[K,V] extendsMap[K,Set[V]]

A trait for mutable maps with multiple values assigned to a key.

A trait for mutable maps with multiple values assigned to a key.

This class is typically used as a mixin. It turns maps which mapK toSet[V] objects into multimaps that mapK toV objects.

Attributes

Example

// first import all necessary types from package `collection.mutable`import collection.mutable.{ HashMap, MultiMap, Set }// to create a `MultiMap` the easiest way is to mixin it into a normal// `Map` instanceval mm = new HashMap[Int, Set[String]] with MultiMap[Int, String]// to add key-value pairs to a multimap it is important to use// the method `addBinding` because standard methods like `+` will// overwrite the complete key-value pair instead of adding the// value to the existing keymm.addBinding(1, "a")mm.addBinding(2, "b")mm.addBinding(1, "c")// mm now contains `Map(2 -> Set(b), 1 -> Set(c, a))`// to check if the multimap contains a value there is method// `entryExists`, which allows to traverse the including setmm.entryExists(1, _ == "a") == truemm.entryExists(1, _ == "b") == falsemm.entryExists(2, _ == "b") == true// to remove a previous added value there is the method `removeBinding`mm.removeBinding(1, "a")mm.entryExists(1, _ == "a") == false
Deprecated
[Since version 2.13.0]Use a scala.collection.mutable.MultiDict in the scala-collection-contrib module
Source
MultiMap.scala
Supertypes
traitMap[K,Set[V]]
traitMapOps[K,Set[V],Map,Map[K,Set[V]]]
traitShrinkable[K]
traitBuilder[(K,Set[V]),Map[K,Set[V]]]
traitGrowable[(K,Set[V])]
traitClearable
traitCloneable[Map[K,Set[V]]]
traitCloneable
traitMap[K,Set[V]]
traitEquals
traitMapOps[K,Set[V],Map,Map[K,Set[V]]]
traitPartialFunction[K,Set[V]]
traitK=>Set[V]
traitIterable[(K,Set[V])]
traitIterable[(K,Set[V])]
traitIterableOps[(K,Set[V]),Iterable,Map[K,Set[V]]]
traitIterableOnceOps[(K,Set[V]),Iterable,Map[K,Set[V]]]
traitIterableOnce[(K,Set[V])]
classObject
traitMatchable
classAny
Show all

Attributes

Companion
class
Deprecated
[Since version 2.13.0]Use HashMap or one of the specialized versions (LongMap, AnyRefMap) instead of OpenHashMap
Source
OpenHashMap.scala
Supertypes
Self type
classOpenHashMap[Key,Value](initialSize:Int) extendsAbstractMap[Key,Value],MapOps[Key,Value,OpenHashMap,OpenHashMap[Key,Value]],StrictOptimizedIterableOps[(Key,Value),Iterable,OpenHashMap[Key,Value]],MapFactoryDefaults[Key,Value,OpenHashMap,Iterable],DefaultSerializable

A mutable hash map based on an open addressing method.

A mutable hash map based on an open addressing method. The precise scheme is undefined, but it should make a reasonable effort to ensure that an insert with consecutive hash codes is not unnecessarily penalised. In particular, mappings of consecutive integer keys should work without significant performance loss.

Type parameters

Key

type of the keys in this map.

Value

type of the values in this map.

Value parameters

initialSize

the initial size of the internal hash table.

Attributes

Companion
object
Deprecated
[Since version 2.13.0]Use HashMap or one of the specialized versions (LongMap, AnyRefMap) instead of OpenHashMap
Source
OpenHashMap.scala
Supertypes
traitStrictOptimizedIterableOps[(Key,Value),Iterable,OpenHashMap[Key,Value]]
classAbstractMap[Key,Value]
traitMap[Key,Value]
traitMapOps[Key,Value,OpenHashMap,OpenHashMap[Key,Value]]
traitShrinkable[Key]
traitBuilder[(Key,Value),OpenHashMap[Key,Value]]
traitGrowable[(Key,Value)]
traitClearable
traitCloneable[OpenHashMap[Key,Value]]
traitCloneable
traitIterable[(Key,Value)]
classAbstractMap[Key,Value]
traitMap[Key,Value]
traitEquals
traitMapOps[Key,Value,OpenHashMap,OpenHashMap[Key,Value]]
traitPartialFunction[Key,Value]
traitKey=>Value
classAbstractIterable[(Key,Value)]
traitIterable[(Key,Value)]
traitIterableOps[(Key,Value),Iterable,OpenHashMap[Key,Value]]
traitIterableOnceOps[(Key,Value),Iterable,OpenHashMap[Key,Value]]
traitIterableOnce[(Key,Value)]
classObject
traitMatchable
classAny
Show all

Deprecated types

typeArrayStack[X] =Stack[X]

Attributes

Deprecated
[Since version 2.13.0]Use Stack instead of ArrayStack; it now uses an array-based implementation
Source
package.scala
typeGrowingBuilder[Elem,To <:Growable[Elem]] =GrowableBuilder[Elem,To]

Attributes

Deprecated
[Since version 2.13.0]GrowingBuilder has been renamed to GrowableBuilder
Source
package.scala

Attributes

Deprecated
[Since version 2.13.0]IndexedOptimizedBuffer has been renamed to IndexedBuffer
Source
package.scala

Attributes

Deprecated
[Since version 2.13.0]IndexedOptimizedSeq has been renamed to IndexedSeq
Source
package.scala
typeLinearSeq[X] =Seq[X] &LinearSeq[X]

Attributes

Deprecated
[Since version 2.13.0]mutable.LinearSeq has been removed; use LinearSeq with mutable.Seq instead
Source
package.scala

Attributes

Deprecated
[Since version 2.13.0]Use Iterable instead of Traversable
Source
package.scala

Attributes

Deprecated
[Since version 2.13.0]Use ArraySeq instead of WrappedArray; it can represent both, boxed and unboxed arrays
Source
package.scala

Value members

Deprecated fields

Attributes

Deprecated
[Since version 2.13.0]Use Stack instead of ArrayStack; it now uses an array-based implementation
Source
package.scala

Attributes

Deprecated
[Since version 2.13.0]Use Iterable instead of Traversable
Source
package.scala

Attributes

Deprecated
[Since version 2.13.0]Use ArraySeq instead of WrappedArray; it can represent both, boxed and unboxed arrays
Source
package.scala
In this article
Generated with
Copyright (c) 2002-2025, LAMP/EPFL
Copyright (c) 2002-2025, LAMP/EPFL

[8]ページ先頭

©2009-2025 Movatter.jp