Scala Library
|
|
scala/collection/immutable/HashSet.scala
]
class
HashSet[A]
extends
Set[A] with
SetClass[A, HashSet] with
SetTemplate[A, HashSet[A]] with
FlatHashTable[A]Value Summary | |
protected var
|
changedElem : A |
protected var
|
deleted : Boolean |
protected var
|
later : HashSet[A] |
Values and Variables inherited from FlatHashTable | |
table, tableSize, threshold |
Method Summary | |
def
|
+
(elem : A) : HashSet[A]
Creates a new set with an additional element, unless the element is
already present.
|
def
|
-
(elem : A) : HashSet[A]
Creates a new set with given element removed from this set, unless the
element is not present.
|
override def
|
companion
: Companion[HashSet]
The factory companion object that builds instances of class CC
|
def
|
contains
(elem : A) : Boolean
Checks if this set contains element
elem . |
override def
|
iterator
: Iterator[A]
Creates a new iterator over all elements contained in this
iterable object.
|
override def
|
size
: Int
Returns the number of entires in this hash table.
|
Methods inherited from FlatHashTable | |
loadFactor, loadFactorDenum, initialSize, findEntry, containsEntry, addEntry, removeEntry, elemHashCode, improve, index, clear |
Methods inherited from Set | |
hashCode |
Methods inherited from SetTemplate | |
newBuilder, isEmpty, apply, intersect, &, **, union, |, diff, &~, subsetOf, equals, stringPrefix, toString |
Methods inherited from Subtractable | |
-, --, -- |
Methods inherited from Addable | |
+, ++, ++ |
Methods inherited from SetClass | |
empty |
Methods inherited from Function1 | |
compose, andThen |
Methods inherited from IterableTemplate | |
elements, foreach, foldRight, reduceRight, toIterable, head, takeRight, dropRight, sameElements, toStream, view, view, first, firstOption, toSeq, projection |
Methods inherited from TraversableClass | |
genericBuilder, unzip, flatten, transpose |
Methods inherited from TraversableTemplate | |
thisCollection, nonEmpty, hasDefiniteSize, ++, ++, map, flatMap, filter, filterMap, filterNot, remove, partition, groupBy, forall, exists, count, find, foldLeft, /:, :\, reduceLeft, reduceLeftOption, reduceRightOption, headOption, tail, last, lastOption, init, take, drop, slice, takeWhile, dropWhile, span, splitAt, copyToBuffer, copyToArray, copyToArray, toArray, toList, toSequence, toSet, mkString, mkString, mkString, addString, addString, addString |
Methods inherited from AnyRef | |
getClass, clone, notify, notifyAll, wait, wait, wait, finalize, ==, !=, eq, ne, synchronized |
Methods inherited from Any | |
==, !=, isInstanceOf, asInstanceOf |
Value Details |
Method Details |
elem
.elem -
the element to check for membership.true
iff elem
is contained in this set.elem -
the element to be addedelem -
the element to be removedoverride
def
size : Int
Scala Library
|
|