Simple JSON  0.1
A free simple json library for C
simple_json_parse.c File Reference
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include "simple_json.h"
#include "simple_json_object.h"
#include "simple_json_array.h"
#include "simple_json_string.h"
#include "simple_json_error.h"
Include dependency graph for simple_json_parse.c:

Go to the source code of this file.

Classes

struct  jsParse
 structure keeps track of the buffer being parsed and the position last used More...
 

Functions

SJsonsj_parse_object (jsParse *parse)
 
SJsonsj_parse_array (jsParse *parse)
 
SJStringsj_parse_string (jsParse *parse)
 
int overseek_check_fail (jsParse *parse)
 
char * get_next_unescaped_char (char *buffer, char target)
 
SJsonsj_parse_value (jsParse *parse)
 
SJsonsj_parse_buffer (char *string, unsigned long length)
 given a string, create a JSON object from it More...
 

Function Documentation

char* get_next_unescaped_char ( char *  buffer,
char  target 
)

Definition at line 35 of file simple_json_parse.c.

int overseek_check_fail ( jsParse parse)

Definition at line 24 of file simple_json_parse.c.

SJson * sj_parse_array ( jsParse parse)

Definition at line 142 of file simple_json_parse.c.

SJson* sj_parse_buffer ( char *  string,
unsigned long  length 
)

given a string, create a JSON object from it

Parameters
stringthe strong to convert. NO OP if this is NULL
lengththe amount of characters in the string
Returns
NULL on error or a JSson object otherwise

Definition at line 234 of file simple_json_parse.c.

SJson * sj_parse_object ( jsParse parse)

Definition at line 182 of file simple_json_parse.c.

SJString * sj_parse_string ( jsParse parse)

Definition at line 50 of file simple_json_parse.c.

SJson* sj_parse_value ( jsParse parse)

Definition at line 115 of file simple_json_parse.c.