* Added experimental binary search API function: xml_binsearch
* Added content parameter to `clicon_rpc_get` (-1 or CONTENT_ALL is default) * Reverted change in clixon-lib.yang
This commit is contained in:
parent
8b7b7b0f60
commit
10a2dbe8ec
17 changed files with 137 additions and 250 deletions
|
|
@ -80,6 +80,7 @@
|
|||
#include <clixon/clixon_yang_module.h>
|
||||
#include <clixon/clixon_stream.h>
|
||||
#include <clixon/clixon_proto.h>
|
||||
#include <clixon/clixon_netconf_lib.h>
|
||||
#include <clixon/clixon_proto_client.h>
|
||||
#include <clixon/clixon_plugin.h>
|
||||
#include <clixon/clixon_options.h>
|
||||
|
|
@ -90,7 +91,6 @@
|
|||
#include <clixon/clixon_xpath_ctx.h>
|
||||
#include <clixon/clixon_xpath.h>
|
||||
#include <clixon/clixon_json.h>
|
||||
#include <clixon/clixon_netconf_lib.h>
|
||||
#include <clixon/clixon_nacm.h>
|
||||
#include <clixon/clixon_xml_changelog.h>
|
||||
#include <clixon/clixon_xml_nsctx.h>
|
||||
|
|
|
|||
|
|
@ -38,6 +38,20 @@
|
|||
#ifndef _CLIXON_NETCONF_LIB_H
|
||||
#define _CLIXON_NETCONF_LIB_H
|
||||
|
||||
/*
|
||||
* Types
|
||||
*/
|
||||
/*! Content query parameter RFC 8040 Sec 4.8.1
|
||||
* Clixon extention: content so that RFC8040 content attribute can be conveyed
|
||||
* internally used in <get>
|
||||
*/
|
||||
enum netconf_content{
|
||||
CONTENT_CONFIG, /* config data only */
|
||||
CONTENT_NONCONFIG, /* state data only */
|
||||
CONTENT_ALL /* default */
|
||||
};
|
||||
typedef enum netconf_content netconf_content;
|
||||
|
||||
/*
|
||||
* Prototypes
|
||||
*/
|
||||
|
|
@ -77,5 +91,7 @@ int netconf_module_features(clicon_handle h);
|
|||
int netconf_module_load(clicon_handle h);
|
||||
char *netconf_db_find(cxobj *xn, char *name);
|
||||
int netconf_err2cb(cxobj *xerr, cbuf **cberr);
|
||||
const netconf_content netconf_content_str2int(char *str);
|
||||
const char *netconf_content_int2str(netconf_content nr);
|
||||
|
||||
#endif /* _CLIXON_NETCONF_LIB_H */
|
||||
|
|
|
|||
|
|
@ -52,8 +52,7 @@ int clicon_rpc_copy_config(clicon_handle h, char *db1, char *db2);
|
|||
int clicon_rpc_delete_config(clicon_handle h, char *db);
|
||||
int clicon_rpc_lock(clicon_handle h, char *db);
|
||||
int clicon_rpc_unlock(clicon_handle h, char *db);
|
||||
int clicon_rpc_get(clicon_handle h, char *xpath, char *namespace, cxobj **xret);
|
||||
int clicon_rpc_get_state(clicon_handle h, char *xpath, char *namespace, cxobj **xret);
|
||||
int clicon_rpc_get(clicon_handle h, char *xpath, char *namespace, netconf_content content, cxobj **xret);
|
||||
int clicon_rpc_close_session(clicon_handle h);
|
||||
int clicon_rpc_kill_session(clicon_handle h, int session_id);
|
||||
int clicon_rpc_validate(clicon_handle h, char *db);
|
||||
|
|
|
|||
|
|
@ -45,5 +45,6 @@ int xml_sort(cxobj *x0, void *arg);
|
|||
int xml_insert(cxobj *xp, cxobj *xc, enum insert_type ins, char *key_val);
|
||||
int xml_sort_verify(cxobj *x, void *arg);
|
||||
int match_base_child(cxobj *x0, cxobj *x1c, yang_stmt *yc, cxobj **x0cp);
|
||||
cxobj *xml_binsearch(cxobj *xp, char *name, char *keyname, char *keyval);
|
||||
|
||||
#endif /* _CLIXON_XML_SORT_H */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue