![]() |
libyang
2.0.194
libyang is YANG data modelling language parser and toolkit written (and providing API) in C.
|
libyang support for YANG extensions implementation. More...
#include "log.h"
#include "plugins.h"
#include "tree_data.h"
#include "tree_edit.h"
#include "tree_schema.h"
#include "plugins_exts_compile.h"
#include "plugins_exts_print.h"
Go to the source code of this file.
Data Structures | |
struct | lyplg_ext |
Extension plugin implementing various aspects of a YANG extension. More... | |
struct | lyplg_ext_record |
Macros | |
#define | LYPLG_EXT_API_VERSION 3 |
Extensions API version. More... | |
#define | LYPLG_EXTENSIONS |
Macro to define plugin information in external plugins. More... | |
Typedefs | |
typedef LY_ERR(* | lyplg_ext_compile_clb) (struct lysc_ctx *cctx, const struct lysp_ext_instance *p_ext, struct lysc_ext_instance *c_ext) |
Callback to compile extension from the lysp_ext_instance to the lysc_ext_instance. The later structure is generally prepared and only the extension specific data are supposed to be added (if any). More... | |
typedef LY_ERR(* | lyplg_ext_data_snode_clb) (struct lysc_ext_instance *ext, const struct lyd_node *parent, const struct lysc_node *sparent, const char *prefix, size_t prefix_len, LY_VALUE_FORMAT format, void *prefix_data, const char *name, size_t name_len, const struct lysc_node **snode) |
Callback for getting a schema node for a new YANG instance data described by an extension instance. Needed only if the extension instance supports some nested standard YANG data. More... | |
typedef LY_ERR(* | lyplg_ext_data_validate_clb) (struct lysc_ext_instance *ext, struct lyd_node *sibling, uint32_t val_opts, struct lyd_node **diff) |
Callback for validating parsed YANG instance data described by an extension instance. More... | |
typedef void(* | lyplg_ext_free_clb) (struct ly_ctx *ctx, struct lysc_ext_instance *ext) |
Callback to free the extension-specific data created by its compilation. More... | |
typedef LY_ERR(* | lyplg_ext_schema_printer_clb) (struct lyspr_ctx *ctx, struct lysc_ext_instance *ext, ly_bool *flag) |
Callback to print the compiled extension instance's private data in the INFO format. More... | |
Functions | |
LIBYANG_API_DECL LY_ERR | lyd_insert_ext (struct lyd_node *parent, struct lyd_node *first) |
Insert extension instance data into a parent. More... | |
LIBYANG_API_DECL LY_ERR | lyplg_ext_get_data (const struct ly_ctx *ctx, const struct lysc_ext_instance *ext, void **ext_data, ly_bool *ext_data_free) |
Get specific run-time extension instance data from a callback set by ly_ctx_set_ext_data_clb(). More... | |
LIBYANG_API_DECL void | lyplg_ext_instance_substatements_free (struct ly_ctx *ctx, struct lysc_ext_substmt *substmts) |
Free the extension instance's data compiled with lys_compile_extension_instance(). More... | |
LIBYANG_API_DECL void | lyplg_ext_log (const struct lysc_ext_instance *ext, LY_LOG_LEVEL level, LY_ERR err_no, const char *path, const char *format,...) |
Provide a log message from an extension plugin. More... | |
libyang support for YANG extensions implementation.
Copyright (c) 2015 - 2019 CESNET, z.s.p.o.
This source code is licensed under BSD 3-Clause License (the "License"). You may not use this file except in compliance with the License. You may obtain a copy of the License at
https://opensource.org/licenses/BSD-3-Clause
Definition in file plugins_exts.h.