Package org.sunflow.util

# Class FastHashMap<K,V>

java.lang.Object
org.sunflow.util.FastHashMap<K,V>

Type Parameters:
  `K` -
  `V` -

All Implemented Interfaces:
  `Iterable<FastHashMap.Entry<K,V>>`

public class FastHashMap<K,V> extends Object implements Iterable<FastHashMap.Entry<K,V>>
Fast hash map implementation which uses array storage along with quadratic probing to resolve collisions. The capacity is doubled when the load goes beyond 50% and is halved when the load drops below 20%.

## Nested Class Summary

Nested Classes
Modifier and Type
Class
Description
`static class`
`FastHashMap.Entry<K,V>`

## Constructor Summary

Constructors
Constructor
Description
`FastHashMap()`

## Method Summary

Modifier and Type
Method
Description
`void`
`clear()`
`boolean`
`containsKey(K k)`
`V`
`get(K k)`
`Iterator<FastHashMap.Entry<K,V>>`
`iterator()`
`V`
`put(K k, V v)`
`void`
`remove(K k)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface java.lang.Iterable

`forEach, spliterator`

## Constructor Details

### FastHashMap

public FastHashMap()

## Method Details

### clear

public void clear()

### put

public V put(K k, V v)

### get

public V get(K k)

### containsKey

public boolean containsKey(K k)

### remove

public void remove(K k)

### iterator

public Iterator<FastHashMap.Entry<K,V>> iterator()

Specified by:
  `iterator` in interface `Iterable<K>`