json_encoder_end_array()

End the current array in the JSON encoder

Synopsis:

#include <sys/json.h>
json_encoder_error_t json_encoder_end_array(json_encoder_t *encoder);

Arguments:

encoder
The JSON encoder instance.

Library:

libjson

Description:

This function ends the encoding of the current array in the given JSON encoder, returning the encoder's nesting level to the array's parent.

Returns:

JSON_ENCODER_OK
Success.
JSON_ENCODER_NO_MEMORY
There is not enough memory to perform the operation.
JSON_ENCODER_BAD_NESTING
The encoder was not previously encoding an array.