146#define VAL_MAX_PLOCKS 1
149#define VAL_MAX_DATARULES 1
152#define VAL_MAX_NUMLEN NCX_MAX_NUMLEN
155#define VAL_BINDEX_CH '['
156#define VAL_EINDEX_CH ']'
158#define VAL_BENUM_CH '('
159#define VAL_EENUM_CH ')'
160#define VAL_INST_SEPCH '.'
161#define VAL_INDEX_SEPCH ','
162#define VAL_INDEX_CLI_SEPCH ' '
163#define VAL_CLI_SEPCH ' '
164#define VAL_QUOTE_CH '\''
165#define VAL_DBLQUOTE_CH '\"'
166#define VAL_EQUAL_CH '='
167#define VAL_XPATH_SEPCH '/'
169#define VAL_XPATH_INDEX_SEPSTR (const xmlChar *)"]["
170#define VAL_XPATH_INDEX_SEPLEN 2
173#define VAL_PASSWORD_STRING (const xmlChar *)"****"
178#define VAL_FL_DUPDONE bit0
181#define VAL_FL_DUPOK bit1
184#define VAL_FL_DEFSET bit2
187#define VAL_FL_META bit3
190#define VAL_FL_DIRTY bit4
193#define VAL_FL_UNIDONE bit5
196#define VAL_FL_DEFVALSET bit6
201#define VAL_FL_DEFVAL bit7
206#define VAL_FL_WITHDEF bit8
209#define VAL_FL_DELETED bit9
214#define VAL_FL_SUBTREE_DIRTY bit10
221#define VAL_FL_CHILD_DELETED bit11
229#define VAL_FL_IS_VAREXPR bit12
234#define VAL_FL_FIXED_VALUE bit13
239#define VAL_FL_EDIT2_MERGE bit14
242#define VAL_FL_EXTERNAL bit15
248#define VAL_FL_FORCE_CONFIG bit16
254#define VAL_FL_FORCE_CONFIG_VALUE bit17
260#define VAL_FL_VALUE_SET bit18
266#define VAL_FL_TEMP_XPATH bit19
271#define VAL_FL_UNCMTD_DELETE bit20
276#define VAL_FL_RECREATED bit21
283#define VAL_FL_SUBTREE_RECREATED bit22
289#define VAL_FL_FROM_TEMPLATE bit23
293#define VAL_FL_CANONICAL bit24
298#define VAL_FL_IS_INDEX bit25
304#define VAL_FL_WILDCARD bit26
309#define VAL_FL_ANYXML_KEY bit27
314#define VAL_FL_ANYXML_CONFIG bit28
321#define VAL_FL_ANYXML_UNKNOWN bit29
324#define VAL_FL_DEFCON_DELETED bit30
334#define VAL_FL_ADDEDIT_DELETED bit31
337/********* val_child_hdr->flags fields ***************/
347#define VAL_FL_GENERIC bit0
350#define VAL_FL_ROOT bit1
353#define VAL_FL_USE_QUE bit2
356#define VAL_FL_USE_TREE bit3
359#define VAL_FL_HDR_DIRTY bit4
362#define VAL_FL_HDR_SUBTREE_DIRTY bit5
367#define VAL_FL_HDR_RECREATED bit6
372#define VAL_FL_HDR_NOT_INSERTED bit7
376#define VAL_VIRTUAL_CACHE_TIME 3
378/* macros to access simple value types */
381#define VAL_OBJ(V) (V)->obj
384#define VAL_OBJTYPE(V) (V)->obj->objtype
387#define VAL_TYPE(V) (V)->btyp
390#define VAL_HDR(V) (V)->hdr
393#define VAL_TYPDEF(V) (V)->typdef
396#define VAL_NSID(V) (V)->nsid
399#define VAL_NAME(V) (V)->name
402#define VAL_RES(V) (V)->res
405#define VAL_BOOL(V) (V)->v.boo
408#define VAL_EMPTY(V) (V)->v.boo
411#define VAL_DOUBLE(V) (V)->v.num.d
414#define VAL_STRING(V) (V)->v.str
420#define VAL_BINARY(V) (V)->v.binary.ustr
423#define VAL_BINARY_LEN(V) (V)->v.binary.ustrlen
426#define VAL_EXTERN_BINARY(V) (V)->extern_binary
429#define VAL_ENU(V) (&(V)->v.enu)
432#define VAL_ENUM(V) (V)->v.enu.val
437#define VAL_ENUM_NAME(V) (V)->v.enu.name
440#define VAL_FLAG(V) (V)->v.boo
443#define VAL_NUMPTR(V) (&(V)->v.num)
446#define VAL_NUM(V) (V)->v.num
449#define VAL_LONG(V) (V)->v.num.l
452#define VAL_INT(V) (V)->v.num.i
455#define VAL_INT8(V) ((int8)((V)->v.num.i))
458#define VAL_L_INT8(V) (V)->v.num.i
461#define VAL_INT16(V) ((int16)((V)->v.num.i))
464#define VAL_L_INT16(V) (V)->v.num.i
467#define VAL_INT32(V) (V)->v.num.i
470#define VAL_INT64(V) (V)->v.num.l
473#define VAL_STR(V) (V)->v.str
476#define VAL_INSTANCE_ID(V) (V)->v.str
479#define VAL_IDREF(V) (&(V)->v.idref)
482#define VAL_IDREF_NSID(V) (V)->v.idref.nsid
485#define VAL_IDREF_NAME(V) (V)->v.idref.name
488#define VAL_IDREF_IDENTITY(V) (V)->v.idref.identity
491#define VAL_UINT(V) (V)->v.num.u
494#define VAL_UINT8(V) ((uint8)((V)->v.num.u))
497#define VAL_L_UINT8(V) (V)->v.num.u
500#define VAL_UINT16(V) ((uint16)((V)->v.num.u))
503#define VAL_L_UINT16(V) (V)->v.num.u
506#define VAL_UINT32(V) (V)->v.num.u
509#define VAL_L_UINT32(V) (V)->v.num.u
512#define VAL_UINT64(V) (V)->v.num.ul
515#define VAL_ULONG(V) (V)->v.num.ul
520#define VAL_DEC64(V) (V)->v.num.dec.val
525#define VAL_DEC64_DIGITS(V) (V)->v.num.dec.digits
530#define VAL_DEC64_ZEROES(V) (V)->v.num.dec.zeroes
533#define VAL_LIST(V) (V)->v.list
536#define VAL_BITS VAL_LIST
540#define VAL_INTERN(V) (V)->v.intbuff
544#define VAL_EXTERN(V) (V)->v.fname
548#define VAL_IS_DELETED(V) ((V)->flags & VAL_FL_DELETED)
551#define VAL_CLR_DELETED(V) (V)->flags &= ~VAL_FL_DELETED
554#define VAL_MARK_DELETED(V) val_mark_deleted(V)
557#define VAL_UNMARK_DELETED(V) val_mark_undeleted(V)
560#define VAL_LAST_MODIFIED(V) (V)->last_modified
563#define VAL_ETAG(V) (V)->etag
566#define VAL_BTYPE(V) (V)->btyp
569#define VAL_SET_VAREXPR(V) (V)->flags |= VAL_FL_IS_VAREXPR
572#define VAL_CLR_VAREXPR(V) (V)->flags &= ~VAL_FL_IS_VAREXPR
575#define VAL_IS_VAREXPR(V) ((V)->flags & VAL_FL_IS_VAREXPR)
578#define VAL_VAREXPR(V) val_get_varexpr(V)
583#define VAL_SET_META(V) (V)->flags |= VAL_FL_META
586#define VAL_REMOVE_META(M) dlq_remove(M)
591#define VAL_SET_FIXED_VALUE(V) (V)->flags |= VAL_FL_FIXED_VALUE
596#define VAL_CLR_FIXED_VALUE(V) (V)->flags &= ~VAL_FL_FIXED_VALUE
601#define VAL_IS_FIXED_VALUE(V) ((V)->flags & VAL_FL_FIXED_VALUE)
604#define VAL_SET_EDIT2_MERGE(V) (V)->flags |= VAL_FL_EDIT2_MERGE
607#define VAL_CLR_EDIT2_MERGE(V) (V)->flags &= ~VAL_FL_EDIT2_MERGE
610#define VAL_IS_EDIT2_MERGE(V) ((V)->flags & VAL_FL_EDIT2_MERGE)
615#define VAL_SET_EXTERNAL(V) (V)->flags |= VAL_FL_EXTERNAL
618#define VAL_CLR_EXTERNAL(V) (V)->flags &= ~VAL_FL_EXTERNAL
621#define VAL_IS_EXTERNAL(V) ((V)->flags & VAL_FL_EXTERNAL)
624#define VAL_SET_VALUE_SET(V) (V)->flags |= VAL_FL_VALUE_SET
627#define VAL_CLR_VALUE_SET(V) (V)->flags &= ~VAL_FL_VALUE_SET
630#define VAL_IS_VALUE_SET(V) ((V)->flags & VAL_FL_VALUE_SET)
633#define VAL_SET_TEMP_XPATH(V) (V)->flags |= VAL_FL_TEMP_XPATH
636#define VAL_CLR_TEMP_XPATH(V) (V)->flags &= ~VAL_FL_TEMP_XPATH
639#define VAL_IS_TEMP_XPATH(V) ((V)->flags & VAL_FL_TEMP_XPATH)
642#define VAL_SET_UNCOMMITTED_DELETE(V) (V)->flags |= VAL_FL_UNCMTD_DELETE
645#define VAL_CLR_UNCOMMITTED_DELETE(V) (V)->flags &= ~VAL_FL_UNCMTD_DELETE
648#define VAL_IS_UNCOMMITTED_DELETE(V) ((V)->flags & VAL_FL_UNCMTD_DELETE)
651#define VAL_SET_RECREATED(V) (V)->flags |= VAL_FL_RECREATED
654#define VAL_CLR_RECREATED(V) (V)->flags &= ~VAL_FL_RECREATED
657#define VAL_IS_RECREATED(V) ((V)->flags & VAL_FL_RECREATED)
660#define VAL_SET_FROM_TEMPLATE(V) (V)->flags |= VAL_FL_FROM_TEMPLATE
663#define VAL_CLR_FROM_TEMPLATE(V) (V)->flags &= ~VAL_FL_FROM_TEMPLATE
666#define VAL_IS_FROM_TEMPLATE(V) ((V)->flags & VAL_FL_FROM_TEMPLATE)
669#define VAL_XPATHPCB(V) val_get_xpathpcb(V)
672#define VAL_SET_CANONICAL(V) (V)->flags |= VAL_FL_CANONICAL
675#define VAL_CLR_CANONICAL(V) (V)->flags &= ~VAL_FL_CANONICAL
678#define VAL_IS_CANONICAL(V) ((V)->flags & VAL_FL_CANONICAL)
681#define VAL_NMDA_ORIGIN(V) (V)->nmda_origin
684#define VAL_IS_INDEX(V) ((V)->flags & VAL_FL_IS_INDEX)
687#define VAL_SET_IS_INDEX(V) (V)->flags |= VAL_FL_IS_INDEX
690#define VAL_CHILD_HDR_OBJ(H) (H)->obj
693#define VAL_CHILD_HDR_COUNT(H) (H)->count
696#define VAL_SET_DEFCON_DELETED(V) (V)->flags |= VAL_FL_DEFCON_DELETED
699#define VAL_CLR_DEFCON_DELETED(V) (V)->flags &= ~VAL_FL_DEFCON_DELETED
702#define VAL_IS_DEFCON_DELETED(V) ((V)->flags & VAL_FL_DEFCON_DELETED)
709#define VAL_SET_ADDEDIT_DELETED(V) (V)->flags |= VAL_FL_ADDEDIT_DELETED
712#define VAL_IS_ADDEDIT_DELETED(V) ((V)->flags & VAL_FL_ADDEDIT_DELETED)
715#define VAL_CLR_ADDEDIT_DELETED(V) (V)->flags &= ~VAL_FL_ADDEDIT_DELETED
722#define VAL_EDITOP(V) (V)->editop
724#define VAL_EXTERN_VALONLY(V) (V)->extern_valonly
729#define VAL_SET_DEFSET(V) (V)->flags |= VAL_FL_DEFSET
735#define VAL_CLR_DEFSET(V) (V)->flags &= ~VAL_FL_DEFSET
737/* Value node is from anydata that was replaced by datapath */
738#define VAL_FROM_ANYDATA(V) (V)->from_anydata
741#define VAL_EXTRA(V) (V)->val_extra
745#define VAL_IS_FORCE_CONFIG(V) ((V)->flags & VAL_FL_FORCE_CONFIG)
747#define VAL_SET_FORCE_CONFIG(V) (V)->flags |= VAL_FL_FORCE_CONFIG
752#define VAL_SET_HDR_RECREATED(V) (V)->flags |= VAL_FL_HDR_RECREATED
755#define VAL_IS_HDR_RECREATED(V) ((V)->flags & VAL_FL_HDR_RECREATED)
783typedef void (*dumpfn_t) (log_debug_t level, const char *fstr, ...);
792typedef void (*errfn_t) (const char *fstr, ...);
801/* pick a log indent function for dump_value */
802typedef void (*indentfn_t) (log_debug_t level, int32 indentcnt);
808typedef struct logfns_t_ {
809 dumpfn_t dumpfn; /**< log dump callback */
810 errfn_t errorfn; /**< log error callback */
811 indentfn_t indentfn; /**< log indent callback */
812 boolean suppressVariableNames; /**< suppress variable names in output */
813 FILE *outputFile; /**< manager redirect to file output */
818typedef struct val_idref_t_ {
819 xmlns_id_t nsid; /**< namespace ID */
822 ncx_identity_t *identity; /**< ID back-ptr if found */
827typedef enum val_insert_mode_t_ {
828 VAL_INS_MODE_NONE, /**< not set */
829 VAL_INS_MODE_KEY, /**< YANG key attribute */
830 VAL_INS_MODE_VALUE, /**< YANG value attribute */
831 VAL_INS_MODE_POINT /**< YANG-API point param */
832} YPACK val_insert_mode_t;
836typedef enum val_dumpvalue_mode_t_ {
837 DUMP_VAL_NONE, /**< not set */
838 DUMP_VAL_STDOUT, /**< dump val to STDOUT */
839 DUMP_VAL_LOG, /**< dump val to main log */
840 DUMP_VAL_ALT_LOG, /**< dump val to alternate log */
841 DUMP_VAL_AUDIT_LOG, /**< dump val to audit log */
842} val_dumpvalue_mode_t;
846typedef struct val_editvars_t_ {
851 struct val_value_t_ *curparent; /**< track the real parent */
852 op_insertop_t insertop; /**< YANG insert operation */
853 xmlChar *insertstr; /**< saved value or key attr */
854 struct xpath_pcb_t_ *insertxpcb; /**< key attr for insert */
855 struct val_value_t_ *insertval; /**< back-ptr if before or after */
856 val_insert_mode_t insert_mode; /**< insert mode requested */
857 uint8 silprio; /**< 2nd SIL priority for server */
858 boolean operset; /**< nc:operation here */
859 void *pcookie; /**< user pointer cookie */
860 int icookie; /**< user integer cookie */
861 boolean is_move; /**< TRUE if YPATCH MOVE operation */
862 boolean skip_sil_partial; /**< TRUE if skip_sil_partial needed */
863 boolean deleted; /**< TRUE if deleted from commit_deletes */
864} YPACK val_editvars_t;
868typedef struct val_extra_t_ {
875 xmlChar *dname; /**< malloced name if needed */
889 struct val_value_t_ *virtualval;
898 struct xpath_pcb_t_ *xpathpcb;
904 plock_cb_t *plock[VAL_MAX_PLOCKS];
910 dlq_hdr_t *dataruleQ; /**< Q of obj_xpath_ptr_t */
923 struct xpath_aio_cb_t_ *aiocb;
930 struct val_value_t_ *leafrefval;
939typedef struct val_value_t_ {
944 struct obj_template_t_ *obj; /**< bptr to object def */
945 typ_def_t *typdef; /**< bptr to typdef if leaf */
946 const xmlChar *name; /**< back pointer to elname\n
947 * the dname field is moved to val_extra_t and only used when
948 * the value is constructed from dummy objects or no objects at all
951 struct val_value_t_ *parent; /**< back-ptr to parent if any */
952 struct val_child_hdr_t_ *hdr; /**< back-ptr to own child_hdr */
955 val_extra_t *val_extra;
957 uint32 flags; /**< internal status flags */
959 xmlns_id_t nsid; /**< namespace ID for this node */
960 ncx_btype_t btyp; /**< base type of this value */
961 ncx_data_class_t dataclass; /**< config or state data */
966 time_t last_modified;
967 ncx_etag_t etag; /**< ETag for RESTCONF */
982 dlq_hdr_t *metaQ; /**< Q of val_value_t */
987 val_editvars_t *editvars; /**< edit-vars from attrs */
988 op_editop_t editop; /**< needed for all edits */
989 status_t res; /**< validation result */
991 /* GET1 getcb moved to val_extra */
992 /* GET1 virtualval moved to val_extra */
993 /* GET1 cachetime moved to val_extra */
996 dlq_hdr_t *indexQ; /**< Q of val_index_t or ncx_filptr_t */
998 /* this field is used for NCX_BT_CHOICE
999 * If set, the object path for this node is really:
1000 * $this --> casobj --> casobj.parent --> $this.parent
1001 * the OBJ_TYP_CASE and OBJ_TYP_CHOICE nodes are skipped
1002 * inside an XML instance document
1004 * replaced by val_get_casobj() function in val_util.h
1005 * struct obj_template_t_ *casobj;
1008 /* xpathpcb moved to val_extra_t */
1010 /* back-ptr to the partial locks that are held
1012 * plock moved to val_extra
1015 /* back-ptr to the data access control rules that
1016 * reference this node
1017 * dataruleQ moved to val_extra
1020 /* malloced pointer to the variable expression found
1021 * if this val node is part of a data template.
1022 * The actual value in union v_ MUST be ignored if
1023 * varexpr string is non-NULL!!
1024 * varexpr moved to val_extra
1030 ncx_owner_id_t owner_id;
1033 ncx_nmda_origin_t nmda_origin;
1036 boolean extern_valonly;
1039 boolean extern_binary;
1048 boolean from_anydata;
1069 dlq_hdr_t child_hdrQ;
1090 val_idref_t idref; /**< NCX_BT_IDREF */
1091 ncx_binary_t binary; /**< NCX_BT_BINARY */
1092 ncx_list_t list; /**< NCX_BT_BITS, NCX_BT_SLIST */
1093 boolean boo; /**< NCX_BT_EMPTY, NCX_BT_BOOLEAN */
1094 ncx_enum_t enu; /**< NCX_BT_UNION, NCX_BT_ENUM */
1095 xmlChar *fname; /**< NCX_BT_EXTERN */
1096 xmlChar *intbuff; /**< NCX_BT_INTERN */
1104typedef struct val_child_hdr_t_ {
1105 dlq_hdr_t qhdr; /**< queue header */
1112 struct obj_template_t_ *obj;
1117 struct val_tree_t_ *tree;
1130} YPACK val_child_hdr_t;
1143typedef struct val_index_t_ {
1144 dlq_hdr_t qhdr; /**< queue header */
1145 val_value_t *val; /**< points to a child node */
1158 (*val_test_fn_t) (const val_value_t *val);
1171 (*val_walker_fn_t) (val_value_t *val,
1187 (*val_walker2_fn_t) (val_child_hdr_t *valhdr,
1203 (*val_hdr_test_fn_t) (val_child_hdr_t *hdr,
1217 (*val_test2_fn_t) (val_value_t *val,
1248 val_new_value (void);
1260 val_init_value (val_value_t *val);
1274 val_init_complex (val_value_t *val,
1288 val_init_virtual (val_value_t *val,
1290 struct obj_template_t_ *obj);
1303 val_init_from_template (val_value_t *val,
1304 struct obj_template_t_ *obj);
1317 val_reinit_from_template (val_value_t *val,
1318 struct obj_template_t_ *obj);
1331 val_free_value (val_value_t *val);
1342 val_set_name (val_value_t *val,
1343 const xmlChar *name,
1357 val_force_dname (val_value_t *val);
1369 val_set_qname (val_value_t *val,
1371 const xmlChar *name,
1385 val_string_ok (typ_def_t *typdef,
1387 const xmlChar *strval);
1405 val_string_ok_errinfo (typ_def_t *typdef,
1407 const xmlChar *strval,
1408 ncx_errinfo_t **errinfo);
1427 val_binary_ok_errinfo (typ_def_t *typdef,
1428 const xmlChar *strval,
1430 ncx_errinfo_t **errinfo);
1451 val_string_ok_ex (ses_cb_t *scb,
1454 const xmlChar *strval,
1455 ncx_errinfo_t **errinfo,
1478 val_string_ok_ex2 (ses_cb_t *scb,
1481 const xmlChar *strval,
1482 ncx_errinfo_t **errinfo,
1508 val_list_ok (typ_def_t *typdef,
1531 val_list_ok_errinfo (typ_def_t *typdef,
1534 ncx_errinfo_t **errinfo);
1550 val_enum_ok (typ_def_t *typdef,
1551 const xmlChar *enumval,
1553 const xmlChar **retstr);
1566 val_bit_ok (typ_def_t *typdef,
1567 const xmlChar *bitname,
1583 val_bitpos_ok (typ_def_t *typdef,
1585 const xmlChar **name);
1607 val_idref_ok (typ_def_t *typdef,
1608 const xmlChar *qname,
1610 const xmlChar **name,
1611 ncx_identity_t **id);
1639 val_idref_ok_ex (typ_def_t *typdef,
1640 const xmlChar *qname,
1643 ncx_module_t *impmod,
1645 const xmlChar **name,
1646 ncx_identity_t **id);
1666 val_parse_idref (ncx_module_t *mod,
1667 const xmlChar *qname,
1669 const xmlChar **name,
1670 ncx_identity_t **id);
1691 val_parse_idref_rootcb (ncx_module_t *mod,
1692 const xmlChar *qname,
1694 const xmlChar **name,
1695 ncx_identity_t **id,
1696 ncx_sm_rootcb_t *rootcb);
1709 val_range_ok (typ_def_t *typdef,
1711 const ncx_num_t *num);
1726 val_range_ok_errinfo (typ_def_t *typdef,
1728 const ncx_num_t *num,
1729 ncx_errinfo_t **errinfo);
1740 val_pattern_ok (typ_def_t *typdef,
1741 const xmlChar *strval);
1757 val_pattern_ok_errinfo (typ_def_t *typdef,
1758 const xmlChar *strval,
1759 ncx_errinfo_t **errinfo);
1772 val_simval_ok (typ_def_t *typdef,
1773 const xmlChar *simval);
1789 val_simval_ok_errinfo (typ_def_t *typdef,
1790 const xmlChar *simval,
1791 ncx_errinfo_t **errinfo);
1808 val_simval_ok_ex (typ_def_t *typdef,
1809 const xmlChar *simval,
1810 ncx_errinfo_t **errinfo,
1830 val_simval_ok_max (typ_def_t *typdef,
1831 const xmlChar *simval,
1832 ncx_errinfo_t **errinfo,
1855 val_simval_ok_max2 (typ_def_t *typdef,
1856 const xmlChar *simval,
1857 ncx_errinfo_t **errinfo,
1883 val_simval_ok_max3 (typ_def_t *typdef,
1884 const xmlChar *simval,
1885 ncx_errinfo_t **errinfo,
1904 val_union_ok (typ_def_t *typdef,
1905 const xmlChar *strval,
1906 val_value_t *retval);
1923 val_union_ok_errinfo (typ_def_t *typdef,
1924 const xmlChar *strval,
1925 val_value_t *retval,
1926 ncx_errinfo_t **errinfo);
1947 val_union_ok_ex (typ_def_t *typdef,
1948 const xmlChar *strval,
1949 val_value_t *retval,
1950 ncx_errinfo_t **errinfo,
1952 typ_def_t **match_typdef);
1976 val_union_ok_binary (typ_def_t *typdef,
1977 const xmlChar *binstr,
1979 val_value_t *retval,
1980 ncx_errinfo_t **errinfo,
1981 typ_def_t **match_typdef);
2004 val_union_ok_full (typ_def_t *typdef,
2005 const xmlChar *strval,
2006 val_value_t *contextval,
2007 val_value_t *rootval,
2008 val_value_t *retval,
2009 ncx_errinfo_t **errinfo);
2019 val_get_metaQ (val_value_t *val);
2030 val_get_first_meta (dlq_hdr_t *queue);
2041 val_get_first_meta_val (val_value_t *val);
2052 val_get_next_meta (val_value_t *curnode);
2063 val_meta_empty (val_value_t *val);
2075 val_find_meta (val_value_t *val,
2077 const xmlChar *name);
2090 val_meta_match (val_value_t *val,
2091 val_value_t *metaval);
2103 val_metadata_inst_count (val_value_t *val,
2105 const xmlChar *name);
2119 val_dump_value (val_value_t *val,
2136 val_dump_value_config (val_value_t *val,
2153 val_dump_value_ex (val_value_t *val,
2155 ncx_display_mode_t display_mode,
2170 val_dump_alt_value (val_value_t *val,
2185 val_stdout_value (val_value_t *val,
2201 val_stdout_value_ex (val_value_t *val,
2203 ncx_display_mode_t display_mode,
2225 val_dump_value_max (val_value_t *val,
2227 int32 indent_amount,
2228 val_dumpvalue_mode_t dumpmode,
2229 ncx_display_mode_t display_mode,
2253 val_dump_value_nonconfig (val_value_t *val,
2255 int32 indent_amount,
2256 val_dumpvalue_mode_t dumpmode,
2257 ncx_display_mode_t display_mode,
2284 val_dump_value_full (val_value_t *val,
2286 int32 indent_amount,
2287 val_dumpvalue_mode_t dumpmode,
2288 ncx_display_mode_t display_mode,
2292 boolean expand_varexpr,
2294 logfns_t *overrideOutput);
2320 val_dump_value_full2 (val_value_t *val,
2322 int32 indent_amount,
2323 val_dumpvalue_mode_t dumpmode,
2324 ncx_display_mode_t display_mode,
2328 boolean expand_varexpr,
2331 logfns_t *overrideOutput);
2347 val_set_string (val_value_t *val,
2348 const xmlChar *valname,
2349 const xmlChar *valstr);
2368 val_set_string2 (val_value_t *val,
2369 const xmlChar *valname,
2371 const xmlChar *valstr,
2396 val_set_string3 (val_value_t *val,
2397 const xmlChar *valname,
2399 const xmlChar *valstr,
2401 boolean is_dblquote);
2420 val_set_binary (const xmlChar *valstr,
2436 val_reset_empty (val_value_t *val);
2452 val_set_simval (val_value_t *val,
2455 const xmlChar *valname,
2456 const xmlChar *valstr);
2502 val_set_simval_str (val_value_t *val,
2505 const xmlChar *valname,
2507 const xmlChar *valstr);
2531 val_set_simval_binary (val_value_t *val,
2532 const xmlChar *binstr,
2580 val_set_simval_max (val_value_t *val,
2583 const xmlChar *valname,
2585 const xmlChar *valstr,
2603 val_make_simval (typ_def_t *typdef,
2605 const xmlChar *valname,
2606 const xmlChar *valstr,
2624 val_make_string (xmlns_id_t nsid,
2625 const xmlChar *valname,
2626 const xmlChar *valstr);
2640 val_make_binary (xmlns_id_t nsid,
2641 const xmlChar *valname,
2642 const xmlChar *valstr,
2658 val_merge (const val_value_t *src,
2669 val_clone (const val_value_t *val);
2680 val_clone2 (const val_value_t *val);
2697 val_clone_config_data (const val_value_t *val,
2719 val_clone_config_newval (const val_value_t *val,
2743 val_clone_config_newval_keys_only (const val_value_t *val,
2767 val_clone_config_save (const val_value_t *val,
2792 val_clone_config_false (const val_value_t *val,
2807 val_replace (val_value_t *val,
2821 val_replace_str (const xmlChar *str,
2837 val_fast_replace_string (const xmlChar *str,
2849 val_replace_stringval (val_value_t *val,
2850 const xmlChar *str);
2870 val_add_child (val_value_t *child,
2871 val_value_t *parent);
2886 val_add_child_sorted (val_value_t *child,
2887 val_value_t *parent);
2902 val_insert_child (val_value_t *child,
2903 val_value_t *current,
2904 val_value_t *parent);
2916 val_remove_child (val_value_t *child);
2929 val_swap_child (val_value_t *newchild,
2930 val_value_t *curchild);
2941 val_first_child_match (const val_value_t *parent,
2942 const val_value_t *child);
2956 val_first_child_match_fast (const val_value_t *parent,
2957 const val_value_t *child,
2958 val_value_t *lastmatch);
2973 val_next_child_match (val_value_t *parent,
2975 val_value_t *curmatch);
2985 val_next_child_same (val_value_t *curchild);
2995 val_get_first_child (const val_value_t *parent);
3005 val_get_next_child (const val_value_t *curchild);
3015 val_get_first_terminal_child (const val_value_t *parent);
3025 val_get_next_terminal_child (const val_value_t *curchild);
3042 val_find_child (const val_value_t *parent,
3043 const xmlChar *modname,
3044 const xmlChar *childname);
3061 val_find_child_fast (const val_value_t *parent,
3063 const xmlChar *childname);
3075 val_find_child_obj (const val_value_t *parent,
3076 const struct obj_template_t_ *chobj);
3094 val_find_child_que (const dlq_hdr_t *childQ,
3096 const xmlChar *childname);
3113 val_match_child (const val_value_t *parent,
3114 const xmlChar *modname,
3115 const xmlChar *childname);
3135 val_match_child_count (const val_value_t *parent,
3136 const xmlChar *modname,
3137 const xmlChar *childname,
3138 uint32 *matchcount);
3158 val_find_next_child (const val_value_t *parent,
3159 const xmlChar *modname,
3160 const xmlChar *childname,
3161 const val_value_t *curchild);
3178 val_find_next_child_fast (const val_value_t *parent,
3179 const val_value_t *curchild);
3191 val_first_child_name (val_value_t *parent,
3192 const xmlChar *name);
3204 val_first_child_qname (val_value_t *parent,
3206 const xmlChar *name);
3219 val_next_child_qname (val_value_t *parent,
3221 const xmlChar *name,
3222 val_value_t *curchild);
3243 val_first_child_string (val_value_t *parent,
3244 const xmlChar *name,
3245 const xmlChar *strval);
3257 val_child_cnt (val_value_t *parent);
3270 val_child_inst_cnt (const val_value_t *parent,
3271 const xmlChar *modname,
3272 const xmlChar *name);
3283 val_get_child_inst_id (const val_value_t *parent,
3284 const val_value_t *child);
3294 val_liststr_count (const val_value_t *val);
3310 val_index_match (const val_value_t *val1,
3311 const val_value_t *val2);
3325 val_index_compare (const val_value_t *val1,
3326 const val_value_t *val2);
3361 val_compare_max (const val_value_t *val1,
3362 const val_value_t *val2,
3405 val_compare_max_def (const val_value_t *val1,
3406 const val_value_t *val2,
3410 boolean ignore_defaults);
3437 val_compare_ex (const val_value_t *val1,
3438 const val_value_t *val2,
3439 boolean configonly);
3463 val_compare (const val_value_t *val1,
3464 const val_value_t *val2);
3487 val_compare_to_string (const val_value_t *val1,
3488 const xmlChar *strval2,
3514 val_compare_to_string_len (const val_value_t *val1,
3515 const xmlChar *strval2,
3527// val_compare_for_replace (const val_value_t *val1,
3528// const val_value_t *val2);
3550 val_compare_for_edit (const val_value_t *val1,
3551 const val_value_t *val2,
3574 val_compare_as_string (const val_value_t *val1,
3575 const val_value_t *val2,
3598 val_sprintf_simval_nc (xmlChar *buff,
3599 const val_value_t *val,
3623 val_sprintf_simval_nc_ex (xmlChar *buff,
3624 const val_value_t *val,
3654 val_sprintf_simval_xpath (xmlChar *buff,
3655 const val_value_t *val,
3687 val_sprintf_binary (xmlChar *buff,
3688 const val_value_t *val,
3706 val_make_sprintf_string (const val_value_t *val);
3722 val_resolve_scoped_name (val_value_t *val,
3723 const xmlChar *name,
3724 val_value_t **chval);
3734 val_get_iqualval (const val_value_t *val);
3756 val_duplicates_allowed (val_value_t *val);
3767 val_has_content (const val_value_t *val);
3779 val_has_content_ex (const val_value_t *val);
3790 val_has_index (const val_value_t *val);
3800 val_get_first_index (const val_value_t *val);
3810 val_get_next_index (const val_index_t *valindex);
3820 val_get_index_count (const val_value_t *val);
3835 val_parse_meta (ses_cb_t *scb,
3838 val_value_t *retval);
3848 val_set_extern (val_value_t *val,
3860 val_set_intern (val_value_t *val,
3883 val_fit_oneline (const val_value_t *val,
3897 val_create_allowed (const val_value_t *val);
3909 val_delete_allowed (const val_value_t *val);
3920 val_is_config_data (const val_value_t *val);
3932 val_is_config_save (const val_value_t *val);
3951 val_is_config_false (const val_value_t *val);
3964 val_is_virtual (const val_value_t *val);
3997 val_get_virtual_value (ses_cb_t *scb,
4022 val_is_default (val_value_t *val);
4035 val_is_real (const val_value_t *val);
4045 val_get_parent_nsid (const val_value_t *val);
4060 val_instance_count (val_value_t *val,
4061 const xmlChar *modname,
4062 const xmlChar *objname);
4080 val_instance_count_fast (val_value_t *val,
4082 const xmlChar *objname,
4083 val_value_t **firstval);
4099 val_instance_count_fast2 (val_value_t *val,
4100 val_value_t *startval);
4119 val_set_extra_instance_errors (val_value_t *val,
4120 const xmlChar *modname,
4121 const xmlChar *objname,
4134 val_need_quotes (const xmlChar *str);
4147 val_has_dquotes (const xmlChar *str);
4158 val_need_dquotes (const xmlChar *str);
4169 val_all_whitespace (const xmlChar *str);
4181 val_any_whitespace (const xmlChar *str,
4194 val_match_metaval (const xml_attr_t *attr,
4196 const xmlChar *name);
4206 val_get_dirty_flag (const val_value_t *val);
4216 val_get_subtree_dirty_flag (const val_value_t *val);
4225 val_set_subtree_dirty_up (val_value_t *val);
4236 val_set_dirty_flag (val_value_t *val,
4246 val_set_child_deleted_flag (val_value_t *val);
4256 val_get_child_deleted_flag (val_value_t *val);
4272 val_clear_dirty_flag (val_value_t *val,
4274 ncx_transaction_id_t txid,
4276 boolean do_clear_default);
4285 val_clear_child_dirty_flag (val_value_t *val);
4295 val_dirty_subtree (const val_value_t *val);
4311 val_clean_tree (val_value_t *val);
4321 val_get_nest_level (val_value_t *val);
4333 val_get_first_leaf (val_value_t *val);
4343extern const xmlChar *
4344 val_get_mod_name (const val_value_t *val);
4354extern const xmlChar *
4355 val_get_mod_prefix (const val_value_t *val);
4365 val_get_nsid (const val_value_t *val);
4375 val_get_yang_sid (const val_value_t *val);
4385 val_change_nsid (val_value_t *val,
4396 val_change_nsid2 (val_value_t *val,
4407 val_change_nsid3 (val_value_t *val,
4423 val_make_from_insertxpcb (val_value_t *sourceval,
4433extern const typ_def_t *
4434 val_get_typdef (const val_value_t *val);
4445 val_set_by_default (const val_value_t *val);
4456 val_has_withdef_default (const val_value_t *val);
4465 val_set_withdef_default (val_value_t *val);
4476 val_is_metaval (const val_value_t *val);
4487 val_move_children (val_value_t *srcval,
4488 val_value_t *destval);
4499 val_move_nonconfig_children (val_value_t *srcval,
4500 val_value_t *destval);
4522 val_cvt_generic (val_value_t *val);
4534 val_set_pcookie (val_value_t *val,
4547 val_set_icookie (val_value_t *val,
4559 val_get_pcookie (val_value_t *val);
4570 val_get_icookie (val_value_t *val);
4581 val_delete_default_leaf (val_value_t *val);
4594 val_delete_default_leaf_list (val_value_t *val);
4603 val_force_empty (val_value_t *val);
4614 val_delete_default_npcon (val_value_t *val);
4626 val_move_fields_for_xml (val_value_t *srcval,
4627 val_value_t *destval,
4639 val_move_metadata (val_value_t *srcval,
4640 val_value_t *destval);
4650 val_get_first_key (val_value_t *val);
4660 val_get_last_key (val_value_t *val);
4670 val_get_next_key (val_index_t *curkey);
4680 val_get_prev_key (val_index_t *curkey);
4690 val_remove_key (val_value_t *keyval);
4700 val_new_deleted_value (void);
4711 val_new_editvars (val_value_t *val);
4722 val_free_editvars (val_value_t *val);
4731 val_free_solo_editvars (val_editvars_t *editvars);
4745 val_all_np_containers (val_value_t *val);
4758 val_sprintf_etag (val_value_t *val,
4770 val_get_last_modified (val_value_t *val);
4779 val_force_default (val_value_t *val);
4790 val_set_all_tags (val_value_t *val,
4792 ncx_transaction_id_t txid);
4801extern const xmlChar *
4802 val_get_owner (val_value_t *val);
4811extern ncx_owner_id_t
4812 val_get_owner_id (val_value_t *val);
4822 val_need_owner_string (val_value_t *val);
4832 val_delete_children (val_value_t *val);
4841 val_clean_value (val_value_t *val);
4853 val_find_bit (val_value_t *val,
4854 const xmlChar *bitname);
4865 val_has_children (const val_value_t *val);
4876 val_add_test_valindex (val_value_t *parentval,
4877 val_value_t *keyval);
4886extern const xmlChar *
4887 val_get_yang_typename (val_value_t *val);
4897 val_set_force_config (val_value_t *val,
4908 val_clear_defvalset_flag (val_value_t *val);
4920 val_clone_valQ (dlq_hdr_t *valQ,
4921 dlq_hdr_t *return_valQ);
4932 val_clean_valQ (dlq_hdr_t *valQ);
4945 val_is_value_set (val_value_t *val);
4956 val_url_encode_string (const xmlChar *str,
4973 val_quote_encode_string (const xmlChar *str,
4988 val_convert_any_to_container (val_value_t *val);
4998 val_clean_index_chain (val_value_t *val);
5009 val_pattern_match (const xmlRegexpPtr pattern,
5010 const xmlChar *strval);
5022 val_ocpattern_match (const regex_t *ocpattern,
5023 const xmlChar *strval);
5036 val_idref_derived_from (ncx_module_t *impmod,
5037 val_value_t *testval,
5038 const xmlChar *qname,
5053 val_set_sil_priority (val_value_t *val,
5064 val_get_sil_priority (val_value_t *val);
5075extern const xmlChar *
5076 val_find_bit_name (val_value_t *val,
5089extern const xmlChar *
5090 val_find_enum_name (val_value_t *val,
5105extern const xmlChar *
5106 val_find_enum_name2 (ncx_btype_t btyp,
5121 val_mark_deleted (val_value_t *val);
5132 val_mark_undeleted (val_value_t *val);
5146 val_has_conditional_value (val_value_t *val);
5160 val_convert_leafref (const val_value_t *val);
5174 val_convert_leafref_ext (val_value_t *val);
5200 val_compare_for_topreplace (const val_value_t *val1,
5201 const val_value_t *val2);
5232 val_compare_for_topreplace_simple (const val_value_t *val1,
5233 const val_value_t *val2);
5244 val_has_complex_child (const val_value_t *val);
5255 val_add_meta (val_value_t *metaval,
5266 val_find_root (val_value_t *val);
5276 val_set_canonical (val_value_t *val);
5287 val_get_leafref_typdef (val_value_t *val);
5310 val_ascendant_compare (val_value_t *val1,
5320extern const xmlChar *
5321 val_get_dname (const val_value_t *val);
5334 val_set_dname (val_value_t *val,
5335 const xmlChar *dname);
5349 val_set_dname2 (val_value_t *val,
5350 const xmlChar *dname,
5362 val_new_extra (val_value_t *val);
5371extern const xmlChar *
5372 val_get_varexpr (const val_value_t *val);
5383 val_set_varexpr (val_value_t *val,
5384 const xmlChar *varexpr);
5393 val_clear_varexpr (val_value_t *val);
5402 val_set_wildcard_string (val_value_t *val);
5411#define val_is_wildcard_string(V) (((V)->flags & VAL_FL_WILDCARD) ? TRUE : FALSE)
5422 val_copy_editvars (const val_value_t *val,
5435 val_set_skip_sil_partial (val_value_t *val);
5445 val_get_skip_sil_partial (const val_value_t *val);
5459 val_get_leafref_typdef_ex (val_value_t *val,
5460 boolean union_check);
5476 val_is_default_npcon (val_value_t *val);
5487 val_identity_ok (typ_def_t *typdef,
5488 ncx_identity_t *ident);
5506 val_highest_bit_set (const val_value_t *val,
5525 val_first_bit_set (const val_value_t *val,
5526 const ncx_lmem_t **lmem,
5545 val_next_bit_set (const val_value_t *val,
5546 const ncx_lmem_t *lmem,
5547 const ncx_lmem_t **nextlmem,
5556extern struct xpath_aio_cb_t_ *
5557 val_get_aiocb (const val_value_t *val);
5568 val_set_aiocb (val_value_t *val,
5569 struct xpath_aio_cb_t_ *aiocb);
5581extern ncx_sm_mpid_t *
5582 val_get_mpid (const val_value_t *val);
5594 val_set_mpid (val_value_t *val,
5595 struct ncx_sm_mpid_t_ *mpid);
5613 val_set_deleted_from_commit_deletes (val_value_t *val,
5631 val_get_deleted_from_commit_deletes (const val_value_t *val);
5644 val_clean_leafref_cache (val_value_t *val);
5676 val_set_child_leaf (val_value_t *parent,
5677 const xmlChar *modname,
5678 const xmlChar *childname,
5679 const xmlChar *valstr);
5718 val_delete_child_leaf (val_value_t *parent,
5719 val_value_t *curparent,
5720 const xmlChar *modname,
5721 const xmlChar *childname);
5727} /* end extern 'C' */
dlq provides general double-linked list and queue support:
NCX System Logging Manager.
YANG module data structures Many internal representations of YANG module constructs.
NETCONF protocol operations.
RFC 57517 partial lock support Data structure definition.
NETCONF Session Common definitions module.
Global error messages for status code enumerations.