NotEmptyMap

@SinceKotools(project = Project.Types, version = "3.1")
interface NotEmptyMap<K, out V> : Map<K, V>

Representation of maps that contain at least one entry.

Parameters

K

The type of map keys.

V

The type of map values.

Types

ConstructionError
Link copied to clipboard
common
object ConstructionError : IllegalArgumentException

Error thrown when creating a NotEmptyMap fails.

Functions

containsKey
Link copied to clipboard
common
abstract fun containsKey(key: K): Boolean
containsValue
Link copied to clipboard
common
abstract fun containsValue(value: V): Boolean
get
Link copied to clipboard
common
abstract operator fun get(key: K): V?
isEmpty
Link copied to clipboard
common
abstract fun isEmpty(): Boolean

Properties

entries
Link copied to clipboard
common
abstract val entries: Set<Map.Entry<K, V>>
head
Link copied to clipboard
common
abstract val head: Pair<K, V>

First entry of this map.

keys
Link copied to clipboard
common
abstract val keys: Set<K>
size
Link copied to clipboard
common
abstract val size: Int
typedSize
Link copied to clipboard
common
open val typedSize: StrictlyPositiveInt

Returns the size of this map as a StrictlyPositiveInt.

values
Link copied to clipboard
common
abstract val values: Collection<V>