|
Scala 2
|
class
HashTable
[ A ]
extends
java.lang.Object with
ScalaObjectHashTable[A]
implements a hashtable
that maps keys of type A
to values of the fully abstract
member type Entry
. Classes that make use of HashTable
have to provide an implementation for Entry
and implement the
function entryKey
.
There are mainly two parameters that affect the performance of a hashtable:
the initial size and the load factor. The size
refers to the number of buckets in the hashtable, and the load
factor is a measure of how full the hashtable is allowed to get before
its size is automatically doubled. Both parameters may be changed by
overriding the corresponding values in class HashTable
.Def Summary | |
protected
|
def
addEntry
( e : Entry )
: scala.Unit
|
protected
|
def
elemEquals
( key1 : A , key2 : A )
: scala.Boolean
|
protected
|
def
elemHashCode
( key : A )
: scala.Int
|
protected
|
def
entries
: Iterator
|
protected
|
def
entryKey
( e : Entry )
: A
|
protected
|
def
findEntry
( key : A )
: Option
|
final protected
|
def
improve
( hcode : scala.Int )
: scala.Int
|
final protected
|
def
index
( hcode : scala.Int )
: scala.Int
|
protected
|
def
initTable
( tb : Array )
: scala.Unit
|
protected
|
def
removeEntry
( key : A )
: scala.Unit
|
def
size
: scala.Int
Returns the size of this hash map. |
Def Detail |
def
addEntry
( e : Entry ) : scala.Unit
def
elemEquals
( key1 : A , key2 : A ) : scala.Boolean
def
elemHashCode
( key : A ) : scala.Int
def
entries
: Iterator
def
entryKey
( e : Entry ) : A
def
findEntry
( key : A ) : Option
def
improve
( hcode : scala.Int ) : scala.Int
def
index
( hcode : scala.Int ) : scala.Int
def
initTable
( tb : Array ) : scala.Unit
def
removeEntry
( key : A ) : scala.Unit
def
size
: scala.Int