[#BloombergLP-bdljsn-JsonArray-insert-0a] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdljsn.adoc[bdljsn]::xref:BloombergLP/bdljsn/JsonArray.adoc[JsonArray]::insert :relfileprefix: ../../../ :mrdocs: Insert at the specified `index` in this JsonArray a copy of the specified `json`, and return an iterator referring to the newly inserted element. If an exception is thrown, `*this` is unaffected. Throw `bsl::length_error` if `size() == maxSize()`. The (template parameter) type `t_INDEX` must be a non‐`bool` integral type. The behavior is undefined unless `index` is in the range `[0 .. size()]`. == Synopsis Declared in `<bdljsn_json.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<class t_INDEX> xref:BloombergLP/bdljsn/JsonArray/Iterator-0d.adoc[JsonArray::Iterator] insert( t_INDEX index, xref:BloombergLP/bdljsn/Json.adoc[Json] const& json) requires bsl::is_integral<t_INDEX>::value && !bsl::is_same<t_INDEX, bool>::value; ---- [.small]#Created with https://www.mrdocs.com[MrDocs]#