Insert [first, last)] at position in the held array.

Synopsis

Declared in <bdljsn_json.h>

template<class t_INPUT_ITERATOR>
JsonArray::Iterator
insert(
    JsonArray::ConstIterator position,
    t_INPUT_ITERATOR first,
    t_INPUT_ITERATOR last);

Description

Insert into the JsonArray held by this object at the specified position the values in the range [first, last)], and return an iterator referring to the first newly inserted element. If an exception is thrown, *this is unaffected. Throw bsl::length_error if size() + distance(first, last) > maxSize(). The behavior is undefined unless isArray() and position is in the range [theArray().begin() .. theArray().end()].

Return Value

an iterator referring to the newly inserted element

Parameters

Name

Description

position

insertion iterator

first

beginning of the source range

last

end of the source range

Created with MrDocs