src/cx/json.h

changeset 1013
add8358fc3c3
parent 1012
21884374edbb
child 1033
e3009345984b
equal deleted inserted replaced
1012:21884374edbb 1013:add8358fc3c3
434 */ 434 */
435 cx_attr_nonnull 435 cx_attr_nonnull
436 void cxJsonDestroy(CxJson *json); 436 void cxJsonDestroy(CxJson *json);
437 437
438 /** 438 /**
439 * Destroys and re-initializes the json interface.
440 *
441 * You might want to use this, to reset the parser after
442 * encountering a syntax error.
443 *
444 * @param json the json interface
445 */
446 cx_attr_nonnull
447 static inline void cxJsonReset(CxJson *json) {
448 const CxAllocator *allocator = json->allocator;
449 cxJsonDestroy(json);
450 cxJsonInit(json, allocator);
451 }
452
453 /**
439 * Adds more data to the input buffer. 454 * Adds more data to the input buffer.
440 * 455 *
441 * The data will be copied. 456 * The data will be copied.
442 * 457 *
443 * @param json the json interface 458 * @param json the json interface

mercurial