yumapro  20.10-12
YumaPro SDK
agt_json_parse.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2008 - 2012, Andy Bierman, All Rights Reserved.
3  * Copyright (c) 2012 - 2021, YumaWorks, Inc., All Rights Reserved.
4  *
5  * Unless required by applicable law or agreed to in writing,
6  * software distributed under the License is distributed on an
7  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
8  * KIND, either express or implied. See the License for the
9  * specific language governing permissions and limitations
10  * under the License.
11  */
12 #if defined(WITH_YANGAPI) || defined(WITH_RESTCONF) || defined(WITH_YCONTROL)
13 #ifndef _H_agt_json_parse
14 #define _H_agt_json_parse
15 
16 /* FILE: agt_json_parse.h
17 *********************************************************************
18 * *
19 * P U R P O S E *
20 * *
21 *********************************************************************/
22 
29 /*********************************************************************
30 * *
31 * C H A N G E H I S T O R Y *
32 * *
33 *********************************************************************
34 
35 date init comment
36 ----------------------------------------------------------------------
37 30-mar-13 abb Begun
38 */
39 
40 #ifndef _H_rpc
41 #include "rpc.h"
42 #endif
43 
44 #ifndef _H_ses
45 #include "ses.h"
46 #endif
47 
48 #ifndef _H_status
49 #include "status.h"
50 #endif
51 
52 #ifndef _H_typ
53 #include "typ.h"
54 #endif
55 
56 #ifndef _H_xml_util
57 #include "xml_util.h"
58 #endif
59 
60 #ifdef __cplusplus
61 extern "C" {
62 #endif
63 
64 /********************************************************************
65 * *
66 * F U N C T I O N S *
67 * *
68 *********************************************************************/
69 
70 
101 extern status_t
102  agt_json_parse_top_identifier (ses_cb_t *scb,
103  xml_msg_hdr_t *msg,
104  obj_template_t *obj,
105  const xmlChar **modname,
106  const xmlChar **name,
107  xmlChar **tempbuff);
108 
109 
135 extern status_t
136  agt_json_parse_text (ses_cb_t *scb,
137  xml_msg_hdr_t *msg,
138  obj_template_t *obj,
139  dlq_hdr_t *returnQ);
140 
144 #ifdef __cplusplus
145 } /* end extern 'C' */
146 #endif
147 
148 #endif /* _H_agt_json_parse */
149 #endif // WITH_YANGAPI || WITH_RESTCONF || WITH_YCONTROL
ncx_str.h
NCX Module Library String Utility Functions.
ses.h
NETCONF Session Common definitions module.
cfg.h
agt_ses.h
Server Session Management.
agt_util.h
Utility Functions for NCX Server method routines.
val.h
Value Node Basic Support.
xml_util.h
XML Utilities.
tk.h
NCX Syntax Token Handler.
log_debug3
void void void void void void void void void void void log_debug3(const char *fstr,...) __attribute__((format(printf
Generate a new LOG_DEBUG_DEBUG3 log entry.
ncx_num.h
NCX Module Library Number Utility Functions.
agt_restcmn_record_error
void agt_restcmn_record_error(ses_cb_t *scb, xml_msg_hdr_t *mhdr, status_t res, val_value_t *errnode, const xmlChar *badval)
Record an rpc-error for YANG-API/RESTCONF response translation.
Definition: agt_restcmn.c:7326
ncxconst.h
Contains NCX constants.
agt_yangapi.h
Yuma REST API Message Handler.
obj_get_mod_prefix
const xmlChar * obj_get_mod_prefix(const obj_template_t *obj)
Get the module prefix for this object.
Definition: obj.c:12125
agt_json_parse.h
JSON input stream parser module.
xpath1.h
XPath 1.0 expression support.
def_reg.h
Definition Registry module.
xpath.h
Schema and data model Xpath search support.
xml_val.h
Utility functions for creating value structs.
agt_json_parse_text
status_t agt_json_parse_text(ses_cb_t *scb, xml_msg_hdr_t *msg, obj_template_t *obj, dlq_hdr_t *returnQ)
Parse token chain representing JSON Text.
Definition: agt_json_parse.c:175
obj_get_name
const xmlChar * obj_get_name(const obj_template_t *obj)
Get the name field for this obj.
Definition: obj.c:10511
val_util.h
Value Node Utilities.
agt_restcmn_record_error_errinfo
void agt_restcmn_record_error_errinfo(ses_cb_t *scb, xml_msg_hdr_t *mhdr, status_t res, val_value_t *errnode, const xmlChar *badval, const ncx_errinfo_t *errinfo)
Record an rpc-error for YANG-API/RESTCONF response translation.
Definition: agt_restcmn.c:7357
rpc.h
NETCONF protocol remote procedure call common definitions.
b64.h
Base64 Utilities.
typ.h
Parameter Type Handler.
tk_get_btype_sym
const char * tk_get_btype_sym(ncx_btype_t btyp)
Get the symbolic token symbol for one of the base types.
Definition: tk.c:3324
yangconst.h
Contains YANG constants separated to prevent H file include loops.
agt.h
Multi-Protocol Network Management Server.
xpath_yang.h
YANG-specific Xpath support.
agt_restcmn_obj_error
void agt_restcmn_obj_error(ses_cb_t *scb, xml_msg_hdr_t *mhdr, status_t res, obj_template_t *errobj, const xmlChar *badval)
Record an rpc-error for YANG-API/RESTCONF response translation.
Definition: agt_restcmn.c:7389
log.h
NCX System Logging Manager.
ncxtypes.h
YANG module data structures Many internal representations of YANG module constructs.
ncx_list.h
NCX Module Library List Utility Functions.
obj_get_basetype
ncx_btype_t obj_get_basetype(const obj_template_t *obj)
Get the NCX base type enum for the object type.
Definition: obj.c:12077
json_parse_text
status_t json_parse_text(ses_cb_t *scb, xml_msg_hdr_t *msg, obj_template_t *obj, dlq_hdr_t *returnQ)
Parse token chain representing JSON Text.
Definition: json_parse.c:2566
agt_json_parse_top_identifier
status_t agt_json_parse_top_identifier(ses_cb_t *scb, xml_msg_hdr_t *msg, obj_template_t *obj, const xmlChar **modname, const xmlChar **name, xmlChar **tempbuff)
Parse a top-level JSON object;.
Definition: agt_json_parse.c:119
ncx.h
YANG module utility functions.
json_parse_top_identifier
status_t json_parse_top_identifier(ses_cb_t *scb, xml_msg_hdr_t *msg, obj_template_t *obj, const xmlChar **modname, const xmlChar **name, xmlChar **tempbuff)
Parse a top-level JSON object;.
Definition: json_parse.c:2440
obj.h
Data Object Support.
json_parse.h
JSON input stream parser module.
xmlns.h
XML namespace support.
status.h
Global error messages for status code enumerations.
dlq.h
dlq provides general double-linked list and queue support:
LOGDEBUG3
#define LOGDEBUG3
Check if at least log-level=debug3.
Definition: log.h:297