MapCollection
interface in package klyn.collections

    public interface MapCollection<K, V>:

MapCollection

Base interface for associative collections.

Properties

Modifier and Type | Member | Description
--- | --- | ---
public readonly property | size `size as ULong` | Gets the number of entries in the collection.

Methods

Modifier and Type | Member | Description
--- | --- | ---
public | clear `clear() as Void` | Clears all entries.
public | containsValue `containsValue(value as V) as Boolean` | Returns true if the value exists.
public | get `get<R>(key as K, defaultValue as R) as R` | Returns the value associated with the key, or the provided default value when the key is absent.
public | items `items() as IList<Tuple<K, V> >` | Returns the items as a list of tuples.
public | keys `keys() as IList<K>` | Returns the keys as a list.
public | remove `remove(key as K) as Boolean` | Removes an entry.
public | values `values() as IList<V>` | Returns the values as a list.

Operators

Modifier and Type | Member | Description
--- | --- | ---
public | operator in(key as K) as Boolean | Returns true if the key exists.
public | operator[](key as K) as V | Gets or sets the value associated with the key.