Added cache for modules-state RFC7895 to avoid building new XML every get call

This commit is contained in:
Olof hagsand 2019-02-21 15:06:20 +01:00
parent a20865846e
commit 3c332b689f
8 changed files with 193 additions and 76 deletions

View file

@ -202,4 +202,8 @@ int clicon_username_set(clicon_handle h, void *username);
int clicon_socket_get(clicon_handle h);
int clicon_socket_set(clicon_handle h, int s);
/*! Set and set module state cache */
cxobj *clicon_module_state_get(clicon_handle h);
int clicon_module_state_set(clicon_handle h, cxobj *xms);
#endif /* _CLIXON_OPTIONS_H_ */

View file

@ -50,8 +50,10 @@
/*
* Prototypes
*/
int modules_state_cache_set(clicon_handle h, cxobj *msx);
int yang_modules_init(clicon_handle h);
char *yang_modules_revision(clicon_handle h);
int yang_modules_state_get(clicon_handle h, yang_spec *yspec, cxobj **xret);
int yang_modules_state_get(clicon_handle h, yang_spec *yspec, char *xpath,
cxobj **xret);
#endif /* _CLIXON_YANG_MODULE_H_ */