klyn.collections.List.addAll
method
public addAll(index as Int, values as Set<T>) as Void
Description

Inserts every element from a set at the requested index.

Set iteration order is implementation-defined.

Parameters
ParameterDescription
indexZero-based insertion index in [0, size].
valuesElements inserted from the set.
Throws
  • IndexException if index is outside [0, size].
Example
import klyn.collections

data = [0, 99]
data.addAll(1, {10, 20})
print(data.size)  # 4