*/
#define JSON_C_OPTION_THREAD (1)
-extern const char *json_number_chars;
-extern const char *json_hex_chars;
-
-/* CAW: added for ANSI C iteration correctness */
+/**
+ * A structure to use with json_object_object_foreachC() loops.
+ * Contains key, val and entry members.
+ */
struct json_object_iter
{
char *key;
struct json_object *val;
struct lh_entry *entry;
};
+typedef struct json_object_iter json_object_iter;
/* forward structure definitions */
-typedef int json_bool;
+/**
+ * @deprecated Unused in json-c sources
+ */
typedef struct printbuf printbuf;
+/**
+ * @deprecated Unused in json-c sources
+ */
typedef struct lh_table lh_table;
+/**
+ * @deprecated Unused in json-c sources
+ */
typedef struct array_list array_list;
+
+typedef int json_bool;
typedef struct json_object json_object;
-typedef struct json_object_iter json_object_iter;
-typedef struct json_tokener json_tokener;
/**
* Type of custom user delete functions. See json_object_set_serializer.
/** Iterate through all keys and values of an object (ANSI C Safe)
* @param obj the json_object instance
- * @param iter the object iterator
+ * @param iter the object iterator, use type json_object_iter
*/
#define json_object_object_foreachC(obj,iter) \
for(iter.entry = json_object_get_object(obj)->head; \
#include "arraylist.h"
#include "json_inttypes.h"
#include "json_object.h"
+#include "json_object_private.h"
#include "json_tokener.h"
#include "json_util.h"
#include "strdup_compat.h"
return json_tokener_errors[jerr];
}
-enum json_tokener_error json_tokener_get_error(json_tokener *tok)
+enum json_tokener_error json_tokener_get_error(struct json_tokener *tok)
{
return tok->err;
}