Loading...
Searching...
No Matches
plugins_types.h
Go to the documentation of this file.
#ifndef LY_PLUGINS_TYPES_H_
#define LY_PLUGINS_TYPES_H_
#include <stddef.h>
#include <stdint.h>
#include "log.h"
#include "ly_config.h"
#include "plugins.h"
#include "set.h"
#include "tree.h"
#include "tree_edit.h"
#ifdef __cplusplus
extern "C" {
#endif
struct ly_ctx;
struct ly_path;
struct lyd_node;
struct lyd_value;
struct lyd_value_xpath10;
struct lys_module;
struct lys_glob_unres;
struct lysc_ident;
struct lysc_node;
struct lysc_pattern;
struct lysc_range;
struct lysc_type;
struct lysc_type_bits;
struct lysc_type_leafref;
#define LYPLG_TYPE_API_VERSION 2
#define LYPLG_TYPES \
uint32_t plugins_types_apiver__ = LYPLG_TYPE_API_VERSION; \
const struct lyplg_type_record plugins_types__[]
#define LYPLG_TYPE_VAL_IS_DYN(type_val) \
(sizeof *(type_val) > LYD_VALUE_FIXED_MEM_SIZE)
#define LYPLG_TYPE_VAL_INLINE_PREPARE(storage, type_val) \
(LYPLG_TYPE_VAL_IS_DYN(type_val) \
? ((type_val) = ((storage)->dyn_mem = calloc(1, sizeof *(type_val)))) \
: ((type_val) = memset((storage)->fixed_mem, 0, sizeof *(type_val))))
#define LYPLG_TYPE_VAL_INLINE_DESTROY(type_val) \
do { if (LYPLG_TYPE_VAL_IS_DYN(type_val)) free(type_val); } while(0)
LIBYANG_API_DECL LY_ERR ly_err_new(struct ly_err_item **err, LY_ERR ecode, LY_VECODE vecode, char *data_path, char *apptag,
const char *err_format, ...) _FORMAT_PRINTF(6, 7);
LIBYANG_API_DECL void ly_err_free(void *ptr);
LIBYANG_API_DECL LY_ERR lyplg_type_check_hints(uint32_t hints, const char *value, size_t value_len, LY_DATA_TYPE type,
int *base, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_check_status(const struct lysc_node *ctx_node, uint16_t val_flags, LY_VALUE_FORMAT format,
void *prefix_data, const char *val_name, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_lypath_check_status(const struct lysc_node *ctx_node, const struct ly_path *path,
LY_VALUE_FORMAT format, void *prefix_data, struct ly_err_item **err);
LIBYANG_API_DECL const struct lys_module *lyplg_type_identity_module(const struct ly_ctx *ctx,
const struct lysc_node *ctx_node, const char *prefix, size_t prefix_len, LY_VALUE_FORMAT format,
const void *prefix_data);
LIBYANG_API_DECL LY_ERR lyplg_type_make_implemented(struct lys_module *mod, const char **features,
struct lys_glob_unres *unres);
LIBYANG_API_DECL size_t lyplg_type_bits_bitmap_size(const struct lysc_type_bits *type);
LIBYANG_API_DECL ly_bool lyplg_type_bits_is_bit_set(const char *bitmap, size_t size, uint32_t bit_position);
LIBYANG_API_DEF LY_ERR lyplg_type_xpath10_print_token(const char *token, uint16_t tok_len, ly_bool is_nametest,
const struct lys_module **context_mod, const struct ly_ctx *resolve_ctx, LY_VALUE_FORMAT resolve_format,
const void *resolve_prefix_data, LY_VALUE_FORMAT get_format, void *get_prefix_data, char **token_p,
struct ly_err_item **err);
LIBYANG_API_DECL const char *lyplg_type_get_prefix(const struct lys_module *mod, LY_VALUE_FORMAT format, void *prefix_data);
LIBYANG_API_DECL LY_ERR lyplg_type_prefix_data_new(const struct ly_ctx *ctx, const void *value, size_t value_len,
LY_VALUE_FORMAT format, const void *prefix_data, LY_VALUE_FORMAT *format_p, void **prefix_data_p);
LIBYANG_API_DECL LY_ERR lyplg_type_prefix_data_dup(const struct ly_ctx *ctx, LY_VALUE_FORMAT format, const void *orig,
void **dup);
LIBYANG_API_DECL void lyplg_type_prefix_data_free(LY_VALUE_FORMAT format, void *prefix_data);
LIBYANG_API_DECL LY_ERR lyplg_type_lypath_new(const struct ly_ctx *ctx, const char *value, size_t value_len,
uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, const struct lysc_node *ctx_node,
struct lys_glob_unres *unres, struct ly_path **path, struct ly_err_item **err);
LIBYANG_API_DECL void lyplg_type_lypath_free(const struct ly_ctx *ctx, struct ly_path *path);
LIBYANG_API_DECL LY_ERR lyplg_type_print_xpath10_value(const struct lyd_value_xpath10 *xp_val, LY_VALUE_FORMAT format,
void *prefix_data, char **str_value, struct ly_err_item **err);
#define LYPLG_TYPE_STORE_DYNAMIC 0x01
#define LYPLG_TYPE_STORE_IMPLEMENT 0x02
#define LYPLG_TYPE_STORE_IS_UTF8 0x04
#define LYPLG_TYPE_STORE_ONLY 0x08
LIBYANG_API_DECL typedef LY_ERR (*lyplg_type_store_clb)(const struct ly_ctx *ctx, const struct lysc_type *type,
const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL typedef LY_ERR (*lyplg_type_validate_clb)(const struct ly_ctx *ctx, const struct lysc_type *type,
const struct lyd_node *ctx_node, const struct lyd_node *tree, struct lyd_value *storage, struct ly_err_item **err);
typedef LY_ERR (*lyplg_type_compare_clb)(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
typedef int (*lyplg_type_sort_clb)(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
typedef const void *(*lyplg_type_print_clb)(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
typedef LY_ERR (*lyplg_type_dup_clb)(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup);
typedef void (*lyplg_type_free_clb)(const struct ly_ctx *ctx, struct lyd_value *value);
struct lyplg_type {
const char *id;
lyplg_type_store_clb store;
lyplg_type_validate_clb validate;
lyplg_type_compare_clb compare;
lyplg_type_sort_clb sort;
lyplg_type_print_clb print;
lyplg_type_dup_clb duplicate;
lyplg_type_free_clb free;
int32_t lyb_data_len;
};
struct lyplg_type_record {
/* plugin identification */
const char *module;
const char *revision;
const char *name;
/* runtime data */
struct lyplg_type plugin;
};
LIBYANG_API_DECL LY_ERR lyplg_type_compare_simple(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DEF int lyplg_type_sort_simple(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL const void *lyplg_type_print_simple(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
LIBYANG_API_DECL LY_ERR lyplg_type_dup_simple(const struct ly_ctx *ctx, const struct lyd_value *original,
struct lyd_value *dup);
LIBYANG_API_DECL void lyplg_type_free_simple(const struct ly_ctx *ctx, struct lyd_value *value);
LIBYANG_API_DECL LY_ERR lyplg_type_store_binary(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value,
size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_compare_binary(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL int lyplg_type_sort_binary(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL const void *lyplg_type_print_binary(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
LIBYANG_API_DECL LY_ERR lyplg_type_dup_binary(const struct ly_ctx *ctx, const struct lyd_value *original,
struct lyd_value *dup);
LIBYANG_API_DECL void lyplg_type_free_binary(const struct ly_ctx *ctx, struct lyd_value *value);
LIBYANG_API_DECL LY_ERR lyplg_type_store_bits(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value,
size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_compare_bits(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DEF int lyplg_type_sort_bits(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL const void *lyplg_type_print_bits(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
LIBYANG_API_DECL LY_ERR lyplg_type_dup_bits(const struct ly_ctx *ctx, const struct lyd_value *original,
struct lyd_value *dup);
LIBYANG_API_DECL void lyplg_type_free_bits(const struct ly_ctx *ctx, struct lyd_value *value);
LIBYANG_API_DECL LY_ERR lyplg_type_store_boolean(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value,
size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_compare_boolean(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DEF int lyplg_type_sort_boolean(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL const void *lyplg_type_print_boolean(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
LIBYANG_API_DECL LY_ERR lyplg_type_store_decimal64(const struct ly_ctx *ctx, const struct lysc_type *type,
const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_compare_decimal64(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DEF int lyplg_type_sort_decimal64(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL const void *lyplg_type_print_decimal64(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
LIBYANG_API_DECL LY_ERR lyplg_type_store_empty(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value,
size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_store_enum(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value,
size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DEF int lyplg_type_sort_enum(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL const void *lyplg_type_print_enum(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
LIBYANG_API_DECL LY_ERR lyplg_type_store_identityref(const struct ly_ctx *ctx, const struct lysc_type *type,
const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_compare_identityref(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DEF int lyplg_type_sort_identityref(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL const void *lyplg_type_print_identityref(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
LIBYANG_API_DECL LY_ERR lyplg_type_store_instanceid(const struct ly_ctx *ctx, const struct lysc_type *type,
const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_validate_instanceid(const struct ly_ctx *ctx, const struct lysc_type *type,
const struct lyd_node *ctx_node, const struct lyd_node *tree, struct lyd_value *storage, struct ly_err_item **err);
LIBYANG_API_DECL const void *lyplg_type_print_instanceid(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
LIBYANG_API_DECL LY_ERR lyplg_type_dup_instanceid(const struct ly_ctx *ctx, const struct lyd_value *original,
struct lyd_value *dup);
LIBYANG_API_DECL void lyplg_type_free_instanceid(const struct ly_ctx *ctx, struct lyd_value *value);
LIBYANG_API_DECL LY_ERR lyplg_type_store_int(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value,
size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_compare_int(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL int lyplg_type_sort_int(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL const void *lyplg_type_print_int(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
LIBYANG_API_DECL LY_ERR lyplg_type_store_uint(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value,
size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_compare_uint(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL int lyplg_type_sort_uint(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL const void *lyplg_type_print_uint(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
LIBYANG_API_DECL LY_ERR lyplg_type_store_leafref(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value,
size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_compare_leafref(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL int lyplg_type_sort_leafref(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL const void *lyplg_type_print_leafref(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
LIBYANG_API_DECL LY_ERR lyplg_type_dup_leafref(const struct ly_ctx *ctx, const struct lyd_value *original,
struct lyd_value *dup);
LIBYANG_API_DECL LY_ERR lyplg_type_validate_leafref(const struct ly_ctx *ctx, const struct lysc_type *type,
const struct lyd_node *ctx_node, const struct lyd_node *tree, struct lyd_value *storage, struct ly_err_item **err);
LIBYANG_API_DECL void lyplg_type_free_leafref(const struct ly_ctx *ctx, struct lyd_value *value);
LIBYANG_API_DECL LY_ERR lyplg_type_store_string(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value,
size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_store_union(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value,
size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_compare_union(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL int lyplg_type_sort_union(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL const void *lyplg_type_print_union(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
LIBYANG_API_DECL LY_ERR lyplg_type_dup_union(const struct ly_ctx *ctx, const struct lyd_value *original,
struct lyd_value *dup);
LIBYANG_API_DECL LY_ERR lyplg_type_validate_union(const struct ly_ctx *ctx, const struct lysc_type *type,
const struct lyd_node *ctx_node, const struct lyd_node *tree, struct lyd_value *storage, struct ly_err_item **err);
LIBYANG_API_DECL void lyplg_type_free_union(const struct ly_ctx *ctx, struct lyd_value *value);
LIBYANG_API_DECL LY_ERR lyplg_type_store_xpath10(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value,
size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints,
const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_compare_xpath10(const struct ly_ctx *ctx, const struct lyd_value *val1,
const struct lyd_value *val2);
LIBYANG_API_DECL const void *lyplg_type_print_xpath10(const struct ly_ctx *ctx, const struct lyd_value *value,
LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len);
LIBYANG_API_DECL LY_ERR lyplg_type_dup_xpath10(const struct ly_ctx *ctx, const struct lyd_value *original,
struct lyd_value *dup);
LIBYANG_API_DECL void lyplg_type_free_xpath10(const struct ly_ctx *ctx, struct lyd_value *value);
LIBYANG_API_DECL LY_ERR lyplg_type_parse_int(const char *datatype, int base, int64_t min, int64_t max, const char *value,
size_t value_len, int64_t *ret, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_parse_uint(const char *datatype, int base, uint64_t max, const char *value,
size_t value_len, uint64_t *ret, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_parse_dec64(uint8_t fraction_digits, const char *value, size_t value_len, int64_t *ret,
struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_identity_isderived(const struct lysc_ident *base, const struct lysc_ident *derived);
LIBYANG_API_DECL LY_ERR lyplg_type_validate_range(LY_DATA_TYPE basetype, struct lysc_range *range, int64_t value,
const char *strval, size_t strval_len, struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_validate_patterns(struct lysc_pattern **patterns, const char *str, size_t str_len,
struct ly_err_item **err);
LIBYANG_API_DECL LY_ERR lyplg_type_resolve_leafref(const struct lysc_type_leafref *lref, const struct lyd_node *node,
struct lyd_value *value, const struct lyd_node *tree, struct ly_set **targets, char **errmsg);
#ifdef __cplusplus
}
#endif
#endif /* LY_PLUGINS_TYPES_H_ */
ly_ctx
libyang context handler.
ly_err_item::err
LY_ERR err
Definition log.h:284
LY_ERR
LY_ERR
libyang's error codes returned by the libyang functions.
Definition log.h:237
ly_err_item
Libyang full error structure.
Definition log.h:282
LY_VECODE
LY_VECODE
libyang's codes of validation error. Whenever ly_errno is set to LY_EVALID, the ly_vecode is also set...
Definition log.h:264
ly_set
Structure to hold a set of (not necessary somehow connected) objects. Usually used for lyd_node,...
Definition set.h:47
lyplg_type_print_binary
LIBYANG_API_DECL const void * lyplg_type_print_binary(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Implementation of lyplg_type_print_clb for the built-in binary type.
lyplg_type_free_binary
LIBYANG_API_DECL void lyplg_type_free_binary(const struct ly_ctx *ctx, struct lyd_value *value)
Implementation of lyplg_type_free_clb for the built-in binary type.
Definition binary.c:474
lyplg_type_dup_binary
LIBYANG_API_DECL LY_ERR lyplg_type_dup_binary(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
Implementation of lyplg_type_dup_clb for the built-in binary type.
Definition binary.c:444
lyplg_type_compare_binary
LIBYANG_API_DECL LY_ERR lyplg_type_compare_binary(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_compare_clb for the built-in binary type.
lyplg_type_store_binary
LIBYANG_API_DECL LY_ERR lyplg_type_store_binary(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of lyplg_type_store_clb for the built-in binary type.
lyplg_type_sort_binary
LIBYANG_API_DECL int lyplg_type_sort_binary(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_sort_clb for the built-in binary type.
lyplg_type_dup_bits
LIBYANG_API_DECL LY_ERR lyplg_type_dup_bits(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
Implementation of the lyplg_type_dup_clb for the built-in bits type.
Definition bits.c:443
lyplg_type_store_bits
LIBYANG_API_DECL LY_ERR lyplg_type_store_bits(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of the lyplg_type_store_clb for the built-in bits type.
lyplg_type_print_bits
LIBYANG_API_DECL const void * lyplg_type_print_bits(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Implementation of the lyplg_type_print_clb for the built-in bits type.
lyplg_type_sort_bits
LIBYANG_API_DEF int lyplg_type_sort_bits(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of the lyplg_type_sort_clb for the built-in bits type.
lyplg_type_compare_bits
LIBYANG_API_DECL LY_ERR lyplg_type_compare_bits(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of the lyplg_type_compare_clb for the built-in bits type.
lyplg_type_free_bits
LIBYANG_API_DECL void lyplg_type_free_bits(const struct ly_ctx *ctx, struct lyd_value *value)
Implementation of the lyplg_type_free_clb for the built-in bits type.
Definition bits.c:483
lyplg_type_sort_boolean
LIBYANG_API_DEF int lyplg_type_sort_boolean(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_sort_clb for the built-in boolean type.
lyplg_type_print_boolean
LIBYANG_API_DECL const void * lyplg_type_print_boolean(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Implementation of lyplg_type_print_clb for the built-in boolean type.
lyplg_type_compare_boolean
LIBYANG_API_DECL LY_ERR lyplg_type_compare_boolean(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_compare_clb for the built-in boolean type.
lyplg_type_store_boolean
LIBYANG_API_DECL LY_ERR lyplg_type_store_boolean(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of lyplg_type_store_clb for the built-in boolean type.
lyplg_type_store_decimal64
LIBYANG_API_DECL LY_ERR lyplg_type_store_decimal64(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of lyplg_type_store_clb for the built-in decimal64 type.
lyplg_type_print_decimal64
LIBYANG_API_DECL const void * lyplg_type_print_decimal64(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Implementation of lyplg_type_print_clb for the built-in decimal64 type.
lyplg_type_compare_decimal64
LIBYANG_API_DECL LY_ERR lyplg_type_compare_decimal64(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_compare_clb for the built-in decimal64 type.
lyplg_type_sort_decimal64
LIBYANG_API_DEF int lyplg_type_sort_decimal64(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_sort_clb for the built-in decimal64 type.
lyplg_type_store_empty
LIBYANG_API_DECL LY_ERR lyplg_type_store_empty(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of lyplg_type_store_clb for the built-in empty type.
lyplg_type_sort_enum
LIBYANG_API_DEF int lyplg_type_sort_enum(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_sort_clb for the built-in enumeration type.
lyplg_type_print_enum
LIBYANG_API_DECL const void * lyplg_type_print_enum(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Implementation of lyplg_type_print_clb for the built-in enumeration type.
lyplg_type_store_enum
LIBYANG_API_DECL LY_ERR lyplg_type_store_enum(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of lyplg_type_store_clb for the built-in enumeration type.
lyplg_type_record::module
const char * module
Definition plugins_types.h:637
lyplg_type::print
lyplg_type_print_clb print
Definition plugins_types.h:628
lyplg_type::store
lyplg_type_store_clb store
Definition plugins_types.h:624
lyplg_type::compare
lyplg_type_compare_clb compare
Definition plugins_types.h:626
lyplg_type::validate
lyplg_type_validate_clb validate
Definition plugins_types.h:625
lyplg_type::lyb_data_len
int32_t lyb_data_len
Definition plugins_types.h:631
lyplg_type::id
const char * id
Definition plugins_types.h:622
lyplg_type_record::name
const char * name
Definition plugins_types.h:643
lyplg_type::duplicate
lyplg_type_dup_clb duplicate
Definition plugins_types.h:629
lyplg_type_record::revision
const char * revision
Definition plugins_types.h:638
lyplg_type::free
lyplg_type_free_clb free
Definition plugins_types.h:630
lyplg_type::sort
lyplg_type_sort_clb sort
Definition plugins_types.h:627
lyplg_type_record::plugin
struct lyplg_type plugin
Definition plugins_types.h:646
lyplg_type_parse_int
LIBYANG_API_DECL LY_ERR lyplg_type_parse_int(const char *datatype, int base, int64_t min, int64_t max, const char *value, size_t value_len, int64_t *ret, struct ly_err_item **err)
Unsigned integer value parser and validator.
lyplg_type_make_implemented
LIBYANG_API_DECL LY_ERR lyplg_type_make_implemented(struct lys_module *mod, const char **features, struct lys_glob_unres *unres)
Implement a module (just like lys_set_implemented()), but keep maintaining unresolved items.
lyplg_type_sort_clb
int(* lyplg_type_sort_clb)(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Callback for sorting values.
Definition plugins_types.h:566
lyplg_type_validate_patterns
LIBYANG_API_DECL LY_ERR lyplg_type_validate_patterns(struct lysc_pattern **patterns, const char *str, size_t str_len, struct ly_err_item **err)
Data type validator for pattern-restricted string values.
lyplg_type_xpath10_print_token
LIBYANG_API_DEF LY_ERR lyplg_type_xpath10_print_token(const char *token, uint16_t tok_len, ly_bool is_nametest, const struct lys_module **context_mod, const struct ly_ctx *resolve_ctx, LY_VALUE_FORMAT resolve_format, const void *resolve_prefix_data, LY_VALUE_FORMAT get_format, void *get_prefix_data, char **token_p, struct ly_err_item **err)
Print xpath1.0 token in the specific format.
Definition xpath1.0.c:41
lyplg_type_validate_clb
LIBYANG_API_DECL typedef LY_ERR(* lyplg_type_validate_clb)(const struct ly_ctx *ctx, const struct lysc_type *type, const struct lyd_node *ctx_node, const struct lyd_node *tree, struct lyd_value *storage, struct ly_err_item **err)
Callback to validate the stored value in the accessible data tree.
Definition plugins_types.h:535
lyplg_type_dup_clb
LY_ERR(* lyplg_type_dup_clb)(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
Callback to duplicate data in the data structure.
Definition plugins_types.h:601
lyplg_type_print_xpath10_value
LIBYANG_API_DECL LY_ERR lyplg_type_print_xpath10_value(const struct lyd_value_xpath10 *xp_val, LY_VALUE_FORMAT format, void *prefix_data, char **str_value, struct ly_err_item **err)
Print xpath1.0 value in the specific format.
Definition xpath1.0.c:213
lyplg_type_parse_uint
LIBYANG_API_DECL LY_ERR lyplg_type_parse_uint(const char *datatype, int base, uint64_t max, const char *value, size_t value_len, uint64_t *ret, struct ly_err_item **err)
Unsigned integer value parser and validator.
lyplg_type_resolve_leafref
LIBYANG_API_DECL LY_ERR lyplg_type_resolve_leafref(const struct lysc_type_leafref *lref, const struct lyd_node *node, struct lyd_value *value, const struct lyd_node *tree, struct ly_set **targets, char **errmsg)
Find leafref target in data.
ly_err_free
LIBYANG_API_DECL LY_ERR LIBYANG_API_DECL void ly_err_free(void *ptr)
Destructor for the error records created with ly_err_new().
lyplg_type_bits_is_bit_set
LIBYANG_API_DECL ly_bool lyplg_type_bits_is_bit_set(const char *bitmap, size_t size, uint32_t bit_position)
Check whether a particular bit of a bitmap is set.
Definition bits.c:83
lyplg_type_store_clb
LIBYANG_API_DECL typedef LY_ERR(* lyplg_type_store_clb)(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Callback to store the given value according to the given type.
Definition plugins_types.h:515
lyplg_type_check_status
LIBYANG_API_DECL LY_ERR lyplg_type_check_status(const struct lysc_node *ctx_node, uint16_t val_flags, LY_VALUE_FORMAT format, void *prefix_data, const char *val_name, struct ly_err_item **err)
Check that the value of a type is allowed based on its status.
lyplg_type_identity_isderived
LIBYANG_API_DECL LY_ERR lyplg_type_identity_isderived(const struct lysc_ident *base, const struct lysc_ident *derived)
Decide if the derived identity is derived from (based on) the base identity.
lyplg_type_validate_range
LIBYANG_API_DECL LY_ERR lyplg_type_validate_range(LY_DATA_TYPE basetype, struct lysc_range *range, int64_t value, const char *strval, size_t strval_len, struct ly_err_item **err)
Data type validator for a range/length-restricted values.
lyplg_type_get_prefix
LIBYANG_API_DECL const char * lyplg_type_get_prefix(const struct lys_module *mod, LY_VALUE_FORMAT format, void *prefix_data)
Get format-specific prefix for a module.
lyplg_type_lypath_check_status
LIBYANG_API_DECL LY_ERR lyplg_type_lypath_check_status(const struct lysc_node *ctx_node, const struct ly_path *path, LY_VALUE_FORMAT format, void *prefix_data, struct ly_err_item **err)
Check that the lypath instance-identifier value is allowed based on the status of the nodes.
lyplg_type_print_clb
const void *(* lyplg_type_print_clb)(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Callback for getting the value of the data stored in value.
Definition plugins_types.h:589
lyplg_type_check_hints
LIBYANG_API_DECL LY_ERR lyplg_type_check_hints(uint32_t hints, const char *value, size_t value_len, LY_DATA_TYPE type, int *base, struct ly_err_item **err)
Check that the type is suitable for the parser's hints (if any) in the specified format.
ly_err_new
LIBYANG_API_DECL LY_ERR ly_err_new(struct ly_err_item **err, LY_ERR ecode, LY_VECODE vecode, char *data_path, char *apptag, const char *err_format,...) _FORMAT_PRINTF(6
Create and fill error structure.
lyplg_type_bits_bitmap_size
LIBYANG_API_DECL size_t lyplg_type_bits_bitmap_size(const struct lysc_type_bits *type)
Get the bitmap size of a bits value bitmap.
Definition bits.c:55
lyplg_type_prefix_data_new
LIBYANG_API_DECL LY_ERR lyplg_type_prefix_data_new(const struct ly_ctx *ctx, const void *value, size_t value_len, LY_VALUE_FORMAT format, const void *prefix_data, LY_VALUE_FORMAT *format_p, void **prefix_data_p)
Store used prefixes in a string into an internal libyang structure used in lyd_value.
lyplg_type_prefix_data_dup
LIBYANG_API_DECL LY_ERR lyplg_type_prefix_data_dup(const struct ly_ctx *ctx, LY_VALUE_FORMAT format, const void *orig, void **dup)
Duplicate prefix data.
lyplg_type_parse_dec64
LIBYANG_API_DECL LY_ERR lyplg_type_parse_dec64(uint8_t fraction_digits, const char *value, size_t value_len, int64_t *ret, struct ly_err_item **err)
Convert a string with a decimal64 value into libyang representation: ret = value * 10^fraction-digits...
lyplg_type_lypath_new
LIBYANG_API_DECL LY_ERR lyplg_type_lypath_new(const struct ly_ctx *ctx, const char *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, const struct lysc_node *ctx_node, struct lys_glob_unres *unres, struct ly_path **path, struct ly_err_item **err)
Helper function to create internal schema path representation for instance-identifier value represent...
lyplg_type_lypath_free
LIBYANG_API_DECL void lyplg_type_lypath_free(const struct ly_ctx *ctx, struct ly_path *path)
Free ly_path structure used by instanceid value representation.
lyplg_type_free_clb
void(* lyplg_type_free_clb)(const struct ly_ctx *ctx, struct lyd_value *value)
Callback for freeing the user type values stored by lyplg_type_store_clb.
Definition plugins_types.h:611
lyplg_type_compare_clb
LY_ERR(* lyplg_type_compare_clb)(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Callback for comparing 2 values of the same type.
Definition plugins_types.h:550
lyplg_type_prefix_data_free
LIBYANG_API_DECL void lyplg_type_prefix_data_free(LY_VALUE_FORMAT format, void *prefix_data)
Free internal prefix data.
lyplg_type_identity_module
LIBYANG_API_DECL const struct lys_module * lyplg_type_identity_module(const struct ly_ctx *ctx, const struct lysc_node *ctx_node, const char *prefix, size_t prefix_len, LY_VALUE_FORMAT format, const void *prefix_data)
Get the corresponding module for the identity value.
lyplg_type
Hold type-specific functions for various operations with the data values.
Definition plugins_types.h:621
lyplg_type_record
Definition plugins_types.h:635
lyplg_type_store_identityref
LIBYANG_API_DECL LY_ERR lyplg_type_store_identityref(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of lyplg_type_store_clb for the built-in identityref type.
Definition identityref.c:232
lyplg_type_print_identityref
LIBYANG_API_DECL const void * lyplg_type_print_identityref(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Implementation of lyplg_type_print_clb for the built-in identityref type.
lyplg_type_compare_identityref
LIBYANG_API_DECL LY_ERR lyplg_type_compare_identityref(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_compare_clb for the built-in identityref type.
lyplg_type_sort_identityref
LIBYANG_API_DEF int lyplg_type_sort_identityref(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_sort_clb for the built-in identityref type.
lyplg_type_validate_instanceid
LIBYANG_API_DECL LY_ERR lyplg_type_validate_instanceid(const struct ly_ctx *ctx, const struct lysc_type *type, const struct lyd_node *ctx_node, const struct lyd_node *tree, struct lyd_value *storage, struct ly_err_item **err)
Implementation of lyplg_type_validate_clb for the built-in instance-identifier type.
lyplg_type_store_instanceid
LIBYANG_API_DECL LY_ERR lyplg_type_store_instanceid(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of lyplg_type_store_clb for the built-in instance-identifier type.
Definition instanceid.c:158
lyplg_type_dup_instanceid
LIBYANG_API_DECL LY_ERR lyplg_type_dup_instanceid(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
Implementation of lyplg_type_dup_clb for the built-in instance-identifier type.
Definition instanceid.c:306
lyplg_type_print_instanceid
LIBYANG_API_DECL const void * lyplg_type_print_instanceid(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Implementation of lyplg_type_print_clb for the built-in instance-identifier type.
Definition instanceid.c:256
lyplg_type_free_instanceid
LIBYANG_API_DECL void lyplg_type_free_instanceid(const struct ly_ctx *ctx, struct lyd_value *value)
Implementation of lyplg_type_free_clb for the built-in instance-identifier type.
Definition instanceid.c:342
lyplg_type_print_uint
LIBYANG_API_DECL const void * lyplg_type_print_uint(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Implementation of lyplg_type_print_clb for the built-in unsigned integer types.
lyplg_type_sort_int
LIBYANG_API_DECL int lyplg_type_sort_int(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_sort_clb for the built-in signed integer types.
lyplg_type_print_int
LIBYANG_API_DECL const void * lyplg_type_print_int(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Implementation of lyplg_type_print_clb for the built-in signed integer types.
lyplg_type_sort_uint
LIBYANG_API_DECL int lyplg_type_sort_uint(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_sort_clb for the built-in unsigned integer types.
lyplg_type_compare_int
LIBYANG_API_DECL LY_ERR lyplg_type_compare_int(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_compare_clb for the built-in signed integer types.
lyplg_type_store_uint
LIBYANG_API_DECL LY_ERR lyplg_type_store_uint(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of lyplg_type_store_clb for the built-in unsigned integer types.
lyplg_type_store_int
LIBYANG_API_DECL LY_ERR lyplg_type_store_int(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of lyplg_type_store_clb for the built-in signed integer types.
lyplg_type_compare_uint
LIBYANG_API_DECL LY_ERR lyplg_type_compare_uint(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_compare_clb for the built-in unsigned integer types.
lyplg_type_compare_leafref
LIBYANG_API_DECL LY_ERR lyplg_type_compare_leafref(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_compare_clb for the built-in leafref type.
Definition leafref.c:105
lyplg_type_validate_leafref
LIBYANG_API_DECL LY_ERR lyplg_type_validate_leafref(const struct ly_ctx *ctx, const struct lysc_type *type, const struct lyd_node *ctx_node, const struct lyd_node *tree, struct lyd_value *storage, struct ly_err_item **err)
Implementation of lyplg_type_validate_clb for the built-in leafref type.
Definition leafref.c:67
lyplg_type_sort_leafref
LIBYANG_API_DECL int lyplg_type_sort_leafref(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_sort_clb for the built-in leafref type.
Definition leafref.c:111
lyplg_type_print_leafref
LIBYANG_API_DECL const void * lyplg_type_print_leafref(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Implementation of lyplg_type_print_clb for the built-in leafref type.
Definition leafref.c:117
lyplg_type_store_leafref
LIBYANG_API_DECL LY_ERR lyplg_type_store_leafref(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of lyplg_type_store_clb for the built-in leafref type.
Definition leafref.c:40
lyplg_type_dup_leafref
LIBYANG_API_DECL LY_ERR lyplg_type_dup_leafref(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
Implementation of lyplg_type_dup_clb for the built-in leafref type.
Definition leafref.c:124
lyplg_type_free_leafref
LIBYANG_API_DECL void lyplg_type_free_leafref(const struct ly_ctx *ctx, struct lyd_value *value)
Implementation of lyplg_type_free_clb for the built-in leafref type.
Definition leafref.c:130
lyplg_type_print_simple
LIBYANG_API_DECL const void * lyplg_type_print_simple(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Implementation of lyplg_type_print_clb for a generic simple type.
lyplg_type_sort_simple
LIBYANG_API_DEF int lyplg_type_sort_simple(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_sort_clb for a generic simple type.
lyplg_type_dup_simple
LIBYANG_API_DECL LY_ERR lyplg_type_dup_simple(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
Implementation of lyplg_type_dup_clb for a generic simple type.
lyplg_type_free_simple
LIBYANG_API_DECL void lyplg_type_free_simple(const struct ly_ctx *ctx, struct lyd_value *value)
Implementation of lyplg_type_free_clb for a generic simple type.
lyplg_type_compare_simple
LIBYANG_API_DECL LY_ERR lyplg_type_compare_simple(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_compare_clb for a generic simple type.
lyplg_type_store_string
LIBYANG_API_DECL LY_ERR lyplg_type_store_string(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of lyplg_type_store_clb for the built-in string type.
lyplg_type_free_union
LIBYANG_API_DECL void lyplg_type_free_union(const struct ly_ctx *ctx, struct lyd_value *value)
Implementation of lyplg_type_free_clb for the built-in union type.
Definition union.c:738
lyplg_type_compare_union
LIBYANG_API_DECL LY_ERR lyplg_type_compare_union(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_compare_clb for the built-in union type.
Definition union.c:556
lyplg_type_print_union
LIBYANG_API_DECL const void * lyplg_type_print_union(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Implementation of lyplg_type_print_clb for the built-in union type.
Definition union.c:659
lyplg_type_sort_union
LIBYANG_API_DECL int lyplg_type_sort_union(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_sort_clb for the built-in union type.
Definition union.c:565
lyplg_type_validate_union
LIBYANG_API_DECL LY_ERR lyplg_type_validate_union(const struct ly_ctx *ctx, const struct lysc_type *type, const struct lyd_node *ctx_node, const struct lyd_node *tree, struct lyd_value *storage, struct ly_err_item **err)
Implementation of lyplg_type_validate_clb for the built-in union type.
Definition union.c:505
lyplg_type_store_union
LIBYANG_API_DECL LY_ERR lyplg_type_store_union(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of lyplg_type_store_clb for the built-in union type.
Definition union.c:450
lyplg_type_dup_union
LIBYANG_API_DECL LY_ERR lyplg_type_dup_union(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
Implementation of lyplg_type_dup_clb for the built-in union type.
Definition union.c:695
lyplg_type_compare_xpath10
LIBYANG_API_DECL LY_ERR lyplg_type_compare_xpath10(const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
Implementation of lyplg_type_compare_clb for the ietf-yang-types xpath1.0 type.
lyplg_type_store_xpath10
LIBYANG_API_DECL LY_ERR lyplg_type_store_xpath10(const struct ly_ctx *ctx, const struct lysc_type *type, const void *value, size_t value_len, uint32_t options, LY_VALUE_FORMAT format, void *prefix_data, uint32_t hints, const struct lysc_node *ctx_node, struct lyd_value *storage, struct lys_glob_unres *unres, struct ly_err_item **err)
Implementation of lyplg_type_store_clb for the ietf-yang-types xpath1.0 type.
lyplg_type_dup_xpath10
LIBYANG_API_DECL LY_ERR lyplg_type_dup_xpath10(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
Implementation of lyplg_type_dup_clb for the ietf-yang-types xpath1.0 type.
Definition xpath1.0.c:479
lyplg_type_free_xpath10
LIBYANG_API_DECL void lyplg_type_free_xpath10(const struct ly_ctx *ctx, struct lyd_value *value)
Implementation of lyplg_type_free_clb for the ietf-yang-types xpath1.0 type.
Definition xpath1.0.c:511
lyplg_type_print_xpath10
LIBYANG_API_DECL const void * lyplg_type_print_xpath10(const struct ly_ctx *ctx, const struct lyd_value *value, LY_VALUE_FORMAT format, void *prefix_data, ly_bool *dynamic, size_t *value_len)
Implementation of lyplg_type_print_clb for the ietf-yang-types xpath1.0 type.
Definition xpath1.0.c:440
lysc_type_leafref::path
struct lyxp_expr * path
Definition tree_schema.h:1366
lys_module
Available YANG schema tree structures representing YANG module.
Definition tree_schema.h:2137
lysc_ident
YANG identity-stmt.
Definition tree_schema.h:1212
lysc_node
Compiled YANG data node.
Definition tree_schema.h:1421
lysc_pattern
Definition tree_schema.h:1261
lysc_range
Definition tree_schema.h:1243
lysc_type
Definition tree_schema.h:1283
lysc_type_bits
Definition tree_schema.h:1348
lysc_type_leafref
Definition tree_schema.h:1359
LY_DATA_TYPE
LY_DATA_TYPE
YANG built-in types.
Definition tree.h:202
LY_VALUE_FORMAT
LY_VALUE_FORMAT
All kinds of supported value formats and prefix mappings to modules.
Definition tree.h:234
log.h
Logger manipulation routines and error definitions.
ly_bool
uint8_t ly_bool
Type to indicate boolean value.
Definition log.h:35
plugins.h
Plugins manipulation.
set.h
Generic set structure and manipulation routines.
tree.h
libyang generic macros and functions to work with YANG schema or data trees.
lyd_node
Generic structure for a data node.
Definition tree_data.h:795
lyd_value
YANG data representation.
Definition tree_data.h:567
lyd_value_xpath10
Special lyd_value structure for ietf-yang-types xpath1.0 values.
Definition tree_data.h:712
tree_edit.h
libyang generic macros and functions to modify YANG schema or data trees. Intended for internal use a...