yyjson_mut_obj_add_strcpy

Function yyjson_mut_obj_add_strcpy 

Source
pub unsafe extern "C" fn yyjson_mut_obj_add_strcpy(
    doc: *mut yyjson_mut_doc,
    obj: *mut yyjson_mut_val,
    key: *const c_char,
    val: *const c_char,
) -> bool
Expand description

Adds a string value at the end of the object. The key and val should be null-terminated UTF-8 strings. The value string is copied. This function allows duplicated key in one object.

@warning The key string is not copied, you should keep the string unmodified for the lifetime of this JSON document.