1#ifdef WITH_SCHEMA_MOUNT
191 const xmlChar *modname,
192 const xmlChar *revision);
208 const xmlChar *prefix);
225 const xmlChar *modname,
226 const xmlChar *revision);
242 const xmlChar *revision,
257 sm_find_module_allroots2 (
const xmlChar *modname,
258 const xmlChar *revision,
274 const xmlChar *objname);
364 const xmlChar *modname,
365 const xmlChar *objname,
607 const xmlChar *label);
620 const xmlChar *modname);
657extern const xmlChar *
777 const xmlChar *modname);
792 const xmlChar *modname);
816#define sm_dump_rootcb(R)
818#define sm_show_rootcb(R)
820#define sm_dump_all_rootcb()
822#define sm_find_module(A,B,C) NULL
824#define sm_find_deviation(A,B,C) NULL
826#define sm_find_module_allroots(A,B,C) NULL
828#define sm_find_any_object(A,B) NULL
830#define sm_first_mounted_obj(R,B) NULL
832#define sm_next_mounted_obj(C,B) NULL
834#define sm_last_mounted_obj(C,B) NULL
836#define sm_prev_mounted_obj(C,B) NULL
838#define sm_setup_cur_rootcb(P)
840#define sm_free_mpid(A)
842#define sm_dump_mpid(M)
844#define sm_clone_mpid(M,V) NULL
846#define sm_get_mpid_from_msg(M) NULL
848#define sm_get_mpi_valroot(P) NULL
850#define sm_get_ancestor_mpid(P) NULL
852#define sm_clear_all_rootcbs(P)
854#define sm_get_first_module(R) NULL
856#define sm_get_rootcb_for_mpid(P) NULL
858#define sm_setup_yanglib(R) ERR_NCX_OPERATION_NOT_SUPPORTED
860#define sm_get_first_anckey(M) NULL
862#define sm_get_next_anckey(M) NULL
status_t
global error return code
Definition: status_enum.h:210
ncx_name_match_t
Node name match modes.
Definition: ncxtypes.h:695
status_t sm_setup_yanglib(ncx_sm_rootcb_t *rootcb)
Setup the YANG library early because the get-sm-yanglib operation is enabled.
Definition: sm.c:2300
void sm_setup_cur_rootcb(ncx_sm_rootcb_t *rootcb)
setup NCX library to use the rootCB for schema mount
Definition: sm.c:959
void sm_cleanup(void)
Cleanup Schema Mount handler.
Definition: sm.c:393
ncx_sm_rootcb_t * sm_save_rootcb(obj_template_t *obj, const xmlChar *label)
Set the with_schema_mount value.
Definition: sm.c:1651
ncx_sm_mpid_t * sm_clone_mpid(const ncx_sm_mpid_t *mpid, val_value_t *valroot)
Clone an existing MPID.
Definition: sm.c:1248
val_value_t * sm_mpid_to_val(ncx_sm_mpid_t *mpid, obj_template_t *mpidobj, boolean preserve, status_t *res)
Convert a "mpid" struct to a YANG container.
Definition: sm.c:2043
ncx_module_t * sm_find_module(ncx_sm_rootcb_t *rootcb, const xmlChar *modname, const xmlChar *revision)
Find an ncx_module_t in the rootcb->modQ.
Definition: sm.c:553
status_t sm_activate_mpid(ncx_sm_rootcb_t *rootcb, ncx_sm_mpid_t *mpid)
Setup a new MPID.
Definition: sm.c:1601
obj_template_t * sm_find_any_object(ncx_sm_rootcb_t *rootcb, const xmlChar *objname)
Check if an obj_template_t is in any module that matches the object name string.
Definition: sm.c:709
void sm_dump_all_rootcb(void)
Print the interesting fields in all rootcbs.
Definition: sm.c:513
ncx_module_t * sm_get_last_module(ncx_sm_rootcb_t *rootcb)
Get the last module from Root Control Block.
Definition: sm.c:1776
void sm_init_yanglib_cb(ncx_yanglib_cb_t *cb)
Init a YANG Library control block struct.
Definition: sm.c:993
ncx_module_t * sm_find_module_allroots(const xmlChar *modname, const xmlChar *revision, boolean withdev)
Find an ncx_module_t in the any rootcb.
Definition: sm.c:633
uint32 sm_mod_revision_count_allroots(xml_msg_hdr_t *msg, const xmlChar *modname)
get the module revision count for all rootcbs
Definition: sm.c:2271
ncx_sm_mpid_t * sm_get_first_mpid(ncx_sm_rootcb_t *rootcb)
Get the first MPID struct in the rootcb.
Definition: sm.c:1553
void sm_dump_mpid(const ncx_sm_mpid_t *mpid)
Dump the contents of a MPID struct if DEBUG.
Definition: sm.c:1188
void sm_init(void)
Initialize Schema Mount handler.
Definition: sm.c:378
ncx_sm_rootcb_t * sm_get_rootcb_for_mpid(ncx_sm_mpid_t *mpid)
Get the rootcb for an MPID.
Definition: sm.c:2217
ncx_module_t * sm_get_first_module(ncx_sm_rootcb_t *rootcb)
Get first module from Root Control Block.
Definition: sm.c:1750
ncx_sm_mpid_t * sm_get_ancestor_mpid(val_value_t *val)
Get the MPID for the specified mounted node.
Definition: sm.c:1455
ncx_sm_rootcb_t * sm_find_rootcb(const xmlChar *label, const xmlChar *modname)
Find a Mount Point Control Block Entry in the rootcbQ.
Definition: sm.c:1683
void sm_free_mpid(ncx_sm_mpid_t *mpid)
free a malloced Mount Point ID control block
Definition: sm.c:1066
obj_template_t * sm_first_mounted_obj(ncx_sm_rootcb_t *rootcb, boolean augment_ok)
Find the first data node.
Definition: sm.c:744
void sm_show_rootcb(ncx_sm_rootcb_t *rootcb)
Print the interesting fields in Root Control block for yangcli report capabilities.
Definition: sm.c:494
void sm_free_rootcb(ncx_sm_rootcb_t *rootcb)
Free a ncx_sm_rootcb_t Control Block record.
Definition: sm.c:1706
obj_template_t * sm_next_mounted_obj(obj_template_t *curobj, boolean augment_ok)
Find the next data node.
Definition: sm.c:776
uint32 sm_mod_revision_count(xml_msg_hdr_t *msg, ncx_sm_rootcb_t *rootcb, const xmlChar *modname)
get the module revision count for one rootcb
Definition: sm.c:2244
void sm_clean_yanglib_cb(ncx_yanglib_cb_t *cb)
Clean a YANG Library control block struct.
Definition: sm.c:1008
void sm_clear_all_rootcbs(dlq_hdr_t *saveQ)
Retrieve all the rootcb entries or clear the rootcbQ.
Definition: sm.c:1876
ncx_module_t * sm_find_deviation(ncx_sm_rootcb_t *rootcb, const xmlChar *modname, const xmlChar *revision)
Find an ncx_module_t in the rootcb->devQ;.
Definition: sm.c:606
val_value_t * sm_get_next_anckey(const val_value_t *curkey)
Get next ancestor key from the MPID.
Definition: sm.c:2194
status_t sm_find_mpidval_from_input(val_value_t *chval, val_value_t **mpidval)
Get the MPID value node from the parsed val_value_t tree prepresenting the ancestors of the action or...
Definition: sm.c:1346
val_value_t * sm_get_mpi_valroot(val_value_t *val)
Get the current value root value.
Definition: sm.c:1395
ncx_sm_mpid_t * sm_get_mpid_from_msg(rpc_msg_t *msg)
Get the MPID struct from the message header if set.
Definition: sm.c:1317
status_t sm_patch_notif_keyQ(const ncx_sm_mpid_t *mpid, dlq_hdr_t *keyQ)
Patch the keyQ for a notification to prepend the SM ancestor keys to the queue.
Definition: sm.c:1515
status_t sm_setup_mpid(xml_msg_hdr_t *msg, val_value_t *val, obj_template_t *obj)
Set Up ancestor keys and yanglib for the current MPI.
Definition: sm.c:1108
void sm_register_yanglib_cbfn(sm_yanglib_cbfn_t cbfn)
register a yanglib_cb setup callback
Definition: sm.c:1028
val_value_t * sm_get_first_anckey(const ncx_sm_mpid_t *mpid)
Get first ancestor key from the MPID.
Definition: sm.c:2174
obj_template_t * sm_find_child_obj(obj_template_t *obj, const xmlChar *modname, const xmlChar *objname, ncx_name_match_t match_names, boolean alt_names, boolean dataonly, status_t *retres)
Find the previous data node.
Definition: sm.c:911
ncx_sm_mpid_t * sm_val_to_mpid(val_value_t *mpidval, boolean preserve, status_t *res)
Convert a "mpid" YANG container to an MPID value.
Definition: sm.c:1949
void sm_dump_rootcb(ncx_sm_rootcb_t *rootcb)
Print the interesting fields in Root Control block Must be debug for some info, debug4 for full info.
Definition: sm.c:473
obj_template_t * sm_prev_mounted_obj(obj_template_t *curobj, boolean augment_ok)
Find the previous data node.
Definition: sm.c:860
obj_template_t * sm_last_mounted_obj(ncx_sm_rootcb_t *rootcb, boolean augment_ok)
Find the first data node.
Definition: sm.c:827
ncx_sm_mpid_t * sm_new_mpid(void)
Malloc and initialize an MPID struct.
Definition: sm.c:1041
ncx_sm_mpid_t * sm_get_next_mpid(ncx_sm_mpid_t *curmpid)
Get the next MPID struct in the rootcb.
Definition: sm.c:1574
ncx_sm_rootcb_t * sm_search_rootcbs(dlq_hdr_t *searchQ, sm_rootcb_searchfn_t searchfn, void *cookie)
search all the rootcbs in the specified queue
Definition: sm.c:1832
YANG module data structures Many internal representations of YANG module constructs.
status_t(* sm_yanglib_cbfn_t)(ncx_sm_rootcb_t *rootcb)
yang library SIL code callback to setup a yanglib_cb
Definition: sm.h:97
boolean(* sm_rootcb_searchfn_t)(ncx_sm_rootcb_t *rootcb, void *cookie)
ROOTCB Search Callback Function.
Definition: sm.h:112
global error status code enumerations
representation of one module or submodule during and after parsing
Definition: ncxtypes.h:1138
Moint Point Instance This struct lives in a val_value_t.val_extra struct.
Definition: ncxtypes.h:1815
Schema Mount Root Control Block used in the object template.
Definition: ncxtypes.h:1893
one context for a yang library.
Definition: ncxtypes.h:1863
One YANG data-def-stmt.
Definition: obj.h:1229
NETCONF Server and Client RPC Request/Reply Message Header.
Definition: rpc.h:181
one value to match one type
Definition: val.h:912
Common Encoding Message Header No longer XML specific!! Used by JSON and CBOR parsing as well!...
Definition: xml_msg.h:404