BsonArray

fun BsonArray(initialCapacity: Int)

Construct an empty BsonArray with the specified initial capacity.

Parameters

initialCapacity

the initial capacity of the BsonArray

Throws

if the specified initial capacity is negative


fun BsonArray(initial: List<BsonValue> = emptyList())

constructs the bson array with an initial list of values, defaults to no items

Parameters

initial

the initial list of BsonValues in the array