Class/Object

eu.shiftforward.apso.collection

HMap

Related Docs: object HMap | package collection

Permalink

class HMap[KeyType[_] <: HMapKey[_]] extends AnyRef

A map containing keys of heterogeneous values. The keys in this map must implement HMapKey[V], where V is the type of its associated key.

KeyType

the type of keys used in this map

Annotations
@deprecated
Deprecated

(Since version 2017/07/13) This will be removed in a future version

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. HMap
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new HMap()

    Permalink

    Creates an HMap with an empty list of entries.

    Creates an HMap with an empty list of entries.

    returns

    a new map containing no entries.

  2. new HMap(entries: ListBuffer[(KeyType[V], V) forSome {type V}])

    Permalink

    entries

    a list of key-value pairs present in the map

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. def ++(other: HMap[KeyType]): HMap[KeyType]

    Permalink

    Creates a new map containing the key/value mappings provided by the specified HMap and all the key/value mappings of this map.

    Creates a new map containing the key/value mappings provided by the specified HMap and all the key/value mappings of this map.

    other

    the map to append

    returns

    a new map containing mappings of this map and those provided by other.

  4. def +=[V](entry: (KeyType[V], V)): HMap.this.type

    Permalink

    Adds a new key/value pair to this map.

    Adds a new key/value pair to this map. If the map already contains a mapping for the key, it will be overridden by the new value.

    V

    the type of the value in entry

    entry

    the key-value pair to update

    returns

    this map.

  5. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  6. def apply[V](key: KeyType[V]): V

    Permalink

    Retrieves the value which is associated with a given key.

    Retrieves the value which is associated with a given key. If the key does not exist in this map, a NoSuchElementException is thrown.

    V

    the type of the value associated with key

    key

    the key to lookup

    returns

    the value associated with the given key.

  7. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  8. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  9. def copy: HMap[KeyType]

    Permalink

    Returns a copy of this map.

    Returns a copy of this map.

    returns

    a copy of this map.

  10. val entries: ListBuffer[(KeyType[V], V) forSome {type V}]

    Permalink

    a list of key-value pairs present in the map

  11. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  12. def equals(oth: Any): Boolean

    Permalink
    Definition Classes
    HMap → AnyRef → Any
  13. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  14. def foreach(f: ((KeyType[V], V) forSome {type V}) ⇒ Unit): Unit

    Permalink

    Applies a function f to all elements of this map.

    Applies a function f to all elements of this map.

    f

    the function that is applied for its side-effect to every element. The result of function f is discarded.

  15. def get[V](key: KeyType[V]): Option[V]

    Permalink

    Optionally returns the value associated with a key.

    Optionally returns the value associated with a key.

    V

    the type of the value associated with key

    key

    the key to lookup

    returns

    an option value containing the value associated with key in this map, or None if none exists.

  16. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  17. def getOrElse[V](key: KeyType[V], default: ⇒ V): V

    Permalink

    Returns the value associated with a key, or a default value if the key is not contained in the map.

    Returns the value associated with a key, or a default value if the key is not contained in the map.

    V

    the type of the value associated with key

    key

    the key to lookup

    default

    a computation that yields a default value in case no binding for key is found in the map

    returns

    the value associated with key if it exists, otherwise the result of the default computation.

  18. def getOrElseUpdate[V](key: KeyType[V], op: ⇒ V): V

    Permalink

    If given key is already in this map, returns associated value.

    If given key is already in this map, returns associated value. Otherwise, computes value from given expression op, stores with key in map and returns that value.

    V

    the type of the value associated with key

    key

    the key to lookup and possibly update

    op

    the computation yielding the value to associate with key, if key is previously unbound

    returns

    the value associated with key (either previously or as a result of executing the method).

  19. def hashCode(): Int

    Permalink
    Definition Classes
    HMap → AnyRef → Any
  20. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  21. def map[A](f: ((KeyType[V], V) forSome {type V}) ⇒ A): ListBuffer[A]

    Permalink

    Builds a new collection by applying a function to all entries of this map.

    Builds a new collection by applying a function to all entries of this map.

    A

    the element type of the returned collection

    f

    the function to apply to each element

    returns

    a new collection resulting from applying the given function f to each element of this map and collecting the results.

  22. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  23. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  24. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  25. def put[V](key: KeyType[V], value: V): HMap.this.type

    Permalink

    Adds a new key/value pair to this map.

    Adds a new key/value pair to this map. If the map already contains a mapping for the key, it will be overridden by the new value.

    V

    the type of the value associated with key

    key

    the key to update

    value

    the new value

    returns

    this map.

  26. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  27. def toString(): String

    Permalink
    Definition Classes
    HMap → AnyRef → Any
  28. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  29. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  30. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped