W3cubDocs

/Kotlin

putAll

fun <K, V> MutableMap<in K, in V>.putAll(
    pairs: Array<out Pair<K, V>>)

Puts all the given pairs into this MutableMap with the first component in the pair being the key and the second the value.

fun <K, V> MutableMap<in K, in V>.putAll(
    pairs: Iterable<Pair<K, V>>)

Puts all the elements of the given collection into this MutableMap with the first component in the pair being the key and the second the value.

fun <K, V> MutableMap<in K, in V>.putAll(
    pairs: Sequence<Pair<K, V>>)

Puts all the elements of the given sequence into this MutableMap with the first component in the pair being the key and the second the value.

© 2010–2018 JetBrains s.r.o.
Licensed under the Apache License, Version 2.0.
https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/put-all.html