remove
Removes the specified key and its corresponding value from this map.
Since Kotlin
1.1Return
the previous value associated with the key, or null
if the key was not present in the map.
Allows to overcome type-safety restriction of remove
that requires to pass a key of type K
.
Removes a single instance of the specified element from this collection, if it is present.
Allows to overcome type-safety restriction of remove
that requires to pass an element of type E
.
Since Kotlin
1.1Return
true
if the element has been successfully removed; false
if it was not present in the collection.
Deprecated (with error)
Use removeAt(index) instead.
Replace with
removeAt(index)
Removes the element at the specified index from this list. In Kotlin one should use the MutableList.removeAt function instead.
Since Kotlin
1.1Removes the specified key and its corresponding value from this map.
Since Kotlin
1.0Return
the previous value associated with the key, or null
if the key was not present in the map.
Allows to overcome type-safety restriction of remove
that requires to pass a key of type K
.
Removes a single instance of the specified element from this collection, if it is present.
Allows to overcome type-safety restriction of remove
that requires to pass an element of type E
.
Since Kotlin
1.0Return
true
if the element has been successfully removed; false
if it was not present in the collection.
Deprecated (with error)
Use removeAt(index) instead.
Replace with
removeAt(index)
Removes the element at the specified index from this list. In Kotlin one should use the MutableList.removeAt function instead.