From 3951d39b40fa5fb9ceaa9182765ca64308c7f583 Mon Sep 17 00:00:00 2001 From: Philipp Stephani Date: Sun, 10 Dec 2017 16:53:01 +0100 Subject: Document that length-aware string functions have been added in 2.7 --- doc/apiref.rst | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'doc') diff --git a/doc/apiref.rst b/doc/apiref.rst index 54d5c7e..7afeb21 100644 --- a/doc/apiref.rst +++ b/doc/apiref.rst @@ -332,6 +332,8 @@ length-aware functions if you wish to embed null bytes in strings. Like :func:`json_string`, but with explicit length, so *value* may contain null characters or not be null terminated. + .. versionadded:: 2.7 + .. function:: json_t *json_string_nocheck(const char *value) .. refcounting:: new @@ -347,6 +349,8 @@ length-aware functions if you wish to embed null bytes in strings. Like :func:`json_string_nocheck`, but with explicit length, so *value* may contain null characters or not be null terminated. + .. versionadded:: 2.7 + .. function:: const char *json_string_value(const json_t *string) Returns the associated value of *string* as a null terminated UTF-8 @@ -361,6 +365,8 @@ length-aware functions if you wish to embed null bytes in strings. Returns the length of *string* in its UTF-8 presentation, or zero if *string* is not a JSON string. + .. versionadded:: 2.7 + .. function:: int json_string_set(json_t *string, const char *value) Sets the associated value of *string* to *value*. *value* must be a @@ -372,6 +378,8 @@ length-aware functions if you wish to embed null bytes in strings. Like :func:`json_string_set`, but with explicit length, so *value* may contain null characters or not be null terminated. + .. versionadded:: 2.7 + .. function:: int json_string_set_nocheck(json_t *string, const char *value) Like :func:`json_string_set`, but doesn't check that *value* is @@ -384,6 +392,8 @@ length-aware functions if you wish to embed null bytes in strings. Like :func:`json_string_set_nocheck`, but with explicit length, so *value* may contain null characters or not be null terminated. + .. versionadded:: 2.7 + Number ====== -- cgit v1.1