plugins CHANGE unify naming in plugins API

All the symbols connected with type plugins are now prefixed by
lyplg_type_ and symbols connected with extensions have lyplg_ext_
prefix.
diff --git a/doc/transition.dox b/doc/transition.dox
index 6b34baa..33e4467 100644
--- a/doc/transition.dox
+++ b/doc/transition.dox
@@ -202,20 +202,19 @@
  * natural way to the specific data type. For example, IPv4 address type is defined as a string with a pattern, but it is
  * more effective and usual to store and handle IPv4 as a 32-bit number.
  *
- * libyang 1.x                  | libyang 2.0                     | Notes
- * :----------------------------|:--------------------------------|:---------------------------------------------------------
- * lys_getnext_union_type()     | -                               | Removed after the type representation redesign.
- * -                            | ::ly_type_identity_isderived()  | Helper functions for base types.
- * -                            | ::ly_type_parse_dec64()         | ^
- * -                            | ::ly_type_parse_int()           | ^
- * -                            | ::ly_type_parse_uint()          | ^
- * -                            | ::ly_type_validate_patterns()   | ^
- * -                            | ::ly_type_validate_range()      | ^
- * -                            | ::ly_type_print_get_prefix()    | Helper functions for processing prefixes in data values.
- * -                            | ::ly_type_store_resolve_prefix() | ^
- * -                            | ::lysc_prefixes_compile()       | ^
- * -                            | ::lysc_prefixes_dup()           | ^
- * -                            | ::lysc_prefixes_free()          | ^
+ * libyang 1.x                  | libyang 2.0                      | Notes
+ * :----------------------------|:---------------------------------|:--------------------------------------------------------
+ * lys_getnext_union_type()     | -                                | Removed after the type representation redesign.
+ * -                            | ::lyplg_type_identity_isderived()| Helper functions for base types.
+ * -                            | ::lyplg_type_parse_dec64()       | ^
+ * -                            | ::lyplg_type_parse_int()         | ^
+ * -                            | ::lyplg_type_parse_uint()        | ^
+ * -                            | ::lyplg_type_validate_patterns() | ^
+ * -                            | ::lyplg_type_validate_range()    | ^
+ * -                            | ::lyplg_type_get_prefix()        | Helper functions for processing prefixes in data values.
+ * -                            | ::lyplg_type_prefix_data_new()   | ^
+ * -                            | ::lyplg_type_prefix_data_dup()   | ^
+ * -                            | ::lyplg_type_prefix_data_free()  | ^
  *
  *
  * Extension implementation is not yet finished. The related functions (lys_ext_*()) from libyang 1.x are not currently
diff --git a/src/log.c b/src/log.c
index d4fbf58..4cfb01c 100644
--- a/src/log.c
+++ b/src/log.c
@@ -584,7 +584,7 @@
 }
 
 API void
-lyext_log(const struct lysc_ext_instance *ext, LY_LOG_LEVEL level, LY_ERR err_no, const char *path, const char *format, ...)
+lyplg_ext_log(const struct lysc_ext_instance *ext, LY_LOG_LEVEL level, LY_ERR err_no, const char *path, const char *format, ...)
 {
     va_list ap;
     char *plugin_msg;
diff --git a/src/plugins_exts.h b/src/plugins_exts.h
index 29e1b6b..271d1ef 100644
--- a/src/plugins_exts.h
+++ b/src/plugins_exts.h
@@ -60,7 +60,7 @@
  * @param[in] substmts The sized array of extension instance's substatements. The whole array is freed except the storage
  * places which are expected to be covered by the extension plugin.
  */
-void lysc_extension_instance_substatements_free(struct ly_ctx *ctx, struct lysc_ext_substmt *substmts);
+void lyplg_ext_instance_substatements_free(struct ly_ctx *ctx, struct lysc_ext_substmt *substmts);
 
 /**
  * @brief Callback to compile extension from the lysp_ext_instance to the lysc_ext_instance. The later structure is generally prepared
@@ -77,15 +77,15 @@
  * @return LY_EVALID in case of non-conforming parsed data.
  * @return LY_ENOT in case the extension instance is not supported and should be removed.
  */
-typedef LY_ERR (*lyext_clb_compile)(struct lysc_ctx *cctx, const struct lysp_ext_instance *p_ext, struct lysc_ext_instance *c_ext);
+typedef LY_ERR (*lyplg_ext_compile_clb)(struct lysc_ctx *cctx, const struct lysp_ext_instance *p_ext, struct lysc_ext_instance *c_ext);
 
 /**
- * @brief Callback to free the extension specific data created by the ::lyext_clb_compile callback of the same extension plugin.
+ * @brief Callback to free the extension specific data created by the ::lyplg_ext_compile_clb callback of the same extension plugin.
  *
  * @param[in] ctx libyang context.
  * @param[in,out] ext Compiled extension structure where the data to free are placed.
  */
-typedef void (*lyext_clb_free)(struct ly_ctx *ctx, struct lysc_ext_instance *ext);
+typedef void (*lyplg_ext_free_clb)(struct ly_ctx *ctx, struct lysc_ext_instance *ext);
 
 /**
  * @brief Callback to decide if data instance is valid according to the schema.
@@ -104,7 +104,7 @@
  * @return LY_SUCCESS on data validation success.
  * @return LY_EVALID in case the validation fails.
  */
-typedef LY_ERR (*lyext_clb_data_validation)(struct lysc_ext_instance *ext, struct lyd_node *node);
+typedef LY_ERR (*lyplg_ext_data_validation_clb)(struct lysc_ext_instance *ext, struct lyd_node *node);
 
 /**
  * @brief Callback to print the compiled extension instance's private data in the INFO format.
@@ -116,18 +116,17 @@
  *
  * @return LY_SUCCESS when everything was fine, other LY_ERR values in case of failure
  */
-typedef LY_ERR (*lyext_clb_schema_printer)(struct lyspr_ctx *ctx, struct lysc_ext_instance *ext, ly_bool *flag);
+typedef LY_ERR (*lyplg_ext_schema_printer_clb)(struct lyspr_ctx *ctx, struct lysc_ext_instance *ext, ly_bool *flag);
 
 /**
  * @brief Extension plugin implementing various aspects of a YANG extension
  */
 struct lyplg_ext {
-    const char *id;                     /**< Plugin identification (mainly for distinguish incompatible versions of the plugins for external tools) */
-    lyext_clb_compile compile;          /**< Callback to compile extension instance from the parsed data */
-    lyext_clb_data_validation validate; /**< Callback to decide if data instance is valid according to the schema. */
-    lyext_clb_schema_printer sprinter;  /**< Callback to print the compiled content (info format) of the extension instance */
-    /* lyext_clb_data_printer dprinter; ? */
-    lyext_clb_free free;                /**< Free the extension instance specific data created by ::lyplg_ext.compile callback */
+    const char *id;                         /**< Plugin identification (mainly for distinguish incompatible versions of the plugins for external tools) */
+    lyplg_ext_compile_clb compile;          /**< Callback to compile extension instance from the parsed data */
+    lyplg_ext_data_validation_clb validate; /**< Callback to decide if data instance is valid according to the schema. */
+    lyplg_ext_schema_printer_clb sprinter;  /**< Callback to print the compiled content (info format) of the extension instance */
+    lyplg_ext_free_clb free;                /**< Free the extension instance specific data created by ::lyplg_ext.compile callback */
 };
 
 struct lyplg_ext_record {
@@ -153,7 +152,8 @@
  * @param[in] path Path relevant to the message.
  * @param[in] format Format string to print.
  */
-void lyext_log(const struct lysc_ext_instance *ext, LY_LOG_LEVEL level, LY_ERR err_no, const char *path, const char *format, ...);
+void lyplg_ext_log(const struct lysc_ext_instance *ext, LY_LOG_LEVEL level, LY_ERR err_no, const char *path,
+        const char *format, ...);
 
 /** @} extensions */
 
diff --git a/src/plugins_exts_compile.h b/src/plugins_exts_compile.h
index 260d1d5..2dfde6a 100644
--- a/src/plugins_exts_compile.h
+++ b/src/plugins_exts_compile.h
@@ -57,7 +57,7 @@
 /** @} scflags */
 
 /**
- * @brief YANG schema compilation context for use in ::lyext_clb_compile callback implementation.
+ * @brief YANG schema compilation context for use in ::lyplg_ext_compile_clb callback implementation.
  *
  * The structure stores complex information connected with the schema compilation process. In the most simple case,
  * the callback is just supposed to pass the provided callback to ::lys_compile_extension_instance() functions.
diff --git a/src/plugins_exts_metadata.c b/src/plugins_exts_metadata.c
index 5d95985..c59c4ed 100644
--- a/src/plugins_exts_metadata.c
+++ b/src/plugins_exts_metadata.c
@@ -37,7 +37,7 @@
 /**
  * @brief Compile annotation extension instances.
  *
- * Implementation of lyext_clb_compile callback set as lyext_plugin::compile.
+ * Implementation of ::lyplg_ext_compile_clb callback set as lyext_plugin::compile.
  */
 static LY_ERR
 annotation_compile(struct lysc_ctx *cctx, const struct lysp_ext_instance *p_ext, struct lysc_ext_instance *c_ext)
@@ -49,14 +49,14 @@
 
     /* annotations can appear only at the top level of a YANG module or submodule */
     if ((c_ext->parent_stmt != LY_STMT_MODULE) && (c_ext->parent_stmt != LY_STMT_SUBMODULE)) {
-        lyext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
+        lyplg_ext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
                 "Extension %s is allowed only at the top level of a YANG module or submodule, but it is placed in \"%s\" statement.",
                 p_ext->name, ly_stmt2str(c_ext->parent_stmt));
         return LY_EVALID;
     }
     /* check mandatory argument */
     if (!c_ext->argument) {
-        lyext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
+        lyplg_ext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
                 "Extension %s is instantiated without mandatory argument representing metadata name.", p_ext->name);
         return LY_EVALID;
     }
@@ -67,7 +67,7 @@
     LY_ARRAY_FOR(mod_c->exts, u) {
         if ((&mod_c->exts[u] != c_ext) && (mod_c->exts[u].def == c_ext->def) && !strcmp(mod_c->exts[u].argument, c_ext->argument)) {
             /* duplication of the same annotation extension in a single module */
-            lyext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx), "Extension %s is instantiated multiple times.", p_ext->name);
+            lyplg_ext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx), "Extension %s is instantiated multiple times.", p_ext->name);
             return LY_EVALID;
         }
     }
@@ -113,14 +113,14 @@
     return ret;
 
 emem:
-    lyext_log(c_ext, LY_LLERR, LY_EMEM, lysc_ctx_get_path(cctx), "Memory allocation failed (%s()).", __func__);
+    lyplg_ext_log(c_ext, LY_LLERR, LY_EMEM, lysc_ctx_get_path(cctx), "Memory allocation failed (%s()).", __func__);
     return LY_EMEM;
 }
 
 /**
  * @brief INFO printer
  *
- * Implementation of lyext_clb_schema_printer set as ::lyext_plugin::sprinter
+ * Implementation of ::lyplg_ext_schema_printer_clb set as ::lyext_plugin::sprinter
  */
 static LY_ERR
 annotation_schema_printer(struct lyspr_ctx *ctx, struct lysc_ext_instance *ext, ly_bool *flag)
@@ -133,7 +133,7 @@
 /**
  * @brief Free annotation extension instances' data.
  *
- * Implementation of lyext_clb_free callback set as ::lyext_plugin::free.
+ * Implementation of ::lyplg_ext_free_clb callback set as ::lyext_plugin::free.
  */
 static void
 annotation_free(struct ly_ctx *ctx, struct lysc_ext_instance *ext)
@@ -142,7 +142,7 @@
         return;
     }
 
-    lysc_extension_instance_substatements_free(ctx, ext->substmts);
+    lyplg_ext_instance_substatements_free(ctx, ext->substmts);
     free(ext->data);
 }
 
diff --git a/src/plugins_exts_nacm.c b/src/plugins_exts_nacm.c
index ed670a8..f80d145 100644
--- a/src/plugins_exts_nacm.c
+++ b/src/plugins_exts_nacm.c
@@ -67,14 +67,14 @@
     return LY_SUCCESS;
 
 emem:
-    lyext_log(arg->c_ext, LY_LLERR, LY_EMEM, NULL, "Memory allocation failed (%s()).", __func__);
+    lyplg_ext_log(arg->c_ext, LY_LLERR, LY_EMEM, NULL, "Memory allocation failed (%s()).", __func__);
     return ret;
 }
 
 /**
  * @brief Compile NAMC's extension instances.
  *
- * Implementation of lyext_clb_compile callback set as lyext_plugin::compile.
+ * Implementation of ::lyplg_ext_compile_clb callback set as lyext_plugin::compile.
  */
 static LY_ERR
 nacm_compile(struct lysc_ctx *cctx, const struct lysp_ext_instance *p_ext, struct lysc_ext_instance *c_ext)
@@ -98,7 +98,7 @@
 
     /* check that the extension is instantiated at an allowed place - data node */
     if (!LY_STMT_IS_NODE(c_ext->parent_stmt)) {
-        lyext_log(c_ext, LY_LLWRN, 0, lysc_ctx_get_path(cctx),
+        lyplg_ext_log(c_ext, LY_LLWRN, 0, lysc_ctx_get_path(cctx),
                 "Extension %s is allowed only in a data nodes, but it is placed in \"%s\" statement.",
                 p_ext->name, ly_stmt2str(c_ext->parent_stmt));
         return LY_ENOT;
@@ -109,7 +109,7 @@
             /* note LYS_AUGMENT and LYS_USES is not in the list since they are not present in the compiled tree. Instead, libyang
              * passes all their extensions to their children nodes */
 invalid_parent:
-            lyext_log(c_ext, LY_LLWRN, 0, lysc_ctx_get_path(cctx),
+            lyplg_ext_log(c_ext, LY_LLWRN, 0, lysc_ctx_get_path(cctx),
                     "Extension %s is not allowed in %s statement.", p_ext->name, lys_nodetype2str(parent->nodetype));
             return LY_ENOT;
         }
@@ -125,10 +125,10 @@
              * We check for all NACM plugins since we want to catch even the situation that there is default-deny-all
              * AND default-deny-write */
             if (parent->exts[u].def == c_ext->def) {
-                lyext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
+                lyplg_ext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
                         "Extension %s is instantiated multiple times.", p_ext->name);
             } else {
-                lyext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
+                lyplg_ext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
                         "Extension nacm:default-deny-write is mixed with nacm:default-deny-all.");
             }
             return LY_EVALID;
diff --git a/src/plugins_exts_print.h b/src/plugins_exts_print.h
index 380c180..9f6fb56 100644
--- a/src/plugins_exts_print.h
+++ b/src/plugins_exts_print.h
@@ -28,7 +28,7 @@
  */
 
 /**
- * @brief YANG printer context for use in ::lyext_clb_schema_printer callback implementation.
+ * @brief YANG printer context for use in ::lyplg_ext_schema_printer_clb callback implementation.
  *
  * The structure provides basic information how the compiled schema is supposed to be printed and where. In the most simple
  * case, the provided context is just passed into ::lysc_print_extension_instance() function which handles printing the
@@ -63,7 +63,7 @@
 /**
  * @brief Print substatements of an extension instance
  *
- * Generic function to access YANG printer functions from the extension plugins (::lyext_clb_schema_printer).
+ * Generic function to access YANG printer functions from the extension plugins (::lyplg_ext_schema_printer_clb).
  *
  * @param[in] ctx YANG printer context to provide output handler and other information for printing.
  * @param[in] ext The compiled extension instance to access the extensions and substatements data.
diff --git a/src/plugins_exts_yangdata.c b/src/plugins_exts_yangdata.c
index 0e921a7..2f1390d 100644
--- a/src/plugins_exts_yangdata.c
+++ b/src/plugins_exts_yangdata.c
@@ -22,18 +22,18 @@
 /**
  * @brief Free yang-data extension instances' data.
  *
- * Implementation of ::lyext_clb_free callback set as lyext_plugin::free.
+ * Implementation of ::lyplg_clb_free_clb callback set as lyext_plugin::free.
  */
 static void
 yangdata_free(struct ly_ctx *ctx, struct lysc_ext_instance *ext)
 {
-    lysc_extension_instance_substatements_free(ctx, ext->substmts);
+    lyplg_ext_instance_substatements_free(ctx, ext->substmts);
 }
 
 /**
  * @brief Compile yang-data extension instances.
  *
- * Implementation of lyext_clb_compile callback set as lyext_plugin::compile.
+ * Implementation of ::lyplg_ext_compile_clb callback set as lyext_plugin::compile.
  */
 static LY_ERR
 yangdata_compile(struct lysc_ctx *cctx, const struct lysp_ext_instance *p_ext, struct lysc_ext_instance *c_ext)
@@ -47,7 +47,7 @@
 
     /* yang-data can appear only at the top level of a YANG module or submodule */
     if ((c_ext->parent_stmt != LY_STMT_MODULE) && (c_ext->parent_stmt != LY_STMT_SUBMODULE)) {
-        lyext_log(c_ext, LY_LLWRN, 0, lysc_ctx_get_path(cctx),
+        lyplg_ext_log(c_ext, LY_LLWRN, 0, lysc_ctx_get_path(cctx),
                 "Extension %s is ignored since it appears as a non top-level statement in \"%s\" statement.",
                 p_ext->name, ly_stmt2str(c_ext->parent_stmt));
         return LY_ENOT;
@@ -59,7 +59,7 @@
     LY_ARRAY_FOR(mod_c->exts, u) {
         if ((&mod_c->exts[u] != c_ext) && (mod_c->exts[u].def == c_ext->def) && !strcmp(mod_c->exts[u].argument, c_ext->argument)) {
             /* duplication of the same yang-data extension in a single module */
-            lyext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx), "Extension %s is instantiated multiple times.", p_ext->name);
+            lyplg_ext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx), "Extension %s is instantiated multiple times.", p_ext->name);
             return LY_EVALID;
         }
     }
@@ -97,12 +97,12 @@
     child = *(struct lysc_node **)c_ext->substmts[0].storage;
     if (!child) {
         valid = 0;
-        lyext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
+        lyplg_ext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
                 "Extension %s is instantiated without any top level data node, but exactly one container data node is expected.",
                 p_ext->name);
     } else if (child->next) {
         valid = 0;
-        lyext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
+        lyplg_ext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
                 "Extension %s is instantiated with multiple top level data nodes, but only a single container data node is allowed.",
                 p_ext->name);
     } else if (child->nodetype == LYS_CHOICE) {
@@ -112,13 +112,13 @@
         while ((snode = lys_getnext(snode, child, mod_c, 0))) {
             if (snode->next) {
                 valid = 0;
-                lyext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
+                lyplg_ext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
                         "Extension %s is instantiated with multiple top level data nodes (inside a single choice's case), "
                         "but only a single container data node is allowed.", p_ext->name);
                 break;
             } else if (snode->nodetype != LYS_CONTAINER) {
                 valid = 0;
-                lyext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
+                lyplg_ext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
                         "Extension %s is instantiated with %s top level data node (inside a choice), "
                         "but only a single container data node is allowed.", p_ext->name, lys_nodetype2str(snode->nodetype));
                 break;
@@ -127,7 +127,7 @@
     } else if (child->nodetype != LYS_CONTAINER) {
         /* via uses */
         valid = 0;
-        lyext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
+        lyplg_ext_log(c_ext, LY_LLERR, LY_EVALID, lysc_ctx_get_path(cctx),
                 "Extension %s is instantiated with %s top level data node, but only a single container data node is allowed.",
                 p_ext->name, lys_nodetype2str(child->nodetype));
     }
@@ -141,14 +141,14 @@
     return LY_SUCCESS;
 
 emem:
-    lyext_log(c_ext, LY_LLERR, LY_EMEM, lysc_ctx_get_path(cctx), "Memory allocation failed (%s()).", __func__);
+    lyplg_ext_log(c_ext, LY_LLERR, LY_EMEM, lysc_ctx_get_path(cctx), "Memory allocation failed (%s()).", __func__);
     return LY_EMEM;
 }
 
 /**
  * @brief INFO printer
  *
- * Implementation of ::lyext_clb_schema_printer set as ::lyext_plugin::sprinter
+ * Implementation of ::lyplg_ext_schema_printer_clb set as ::lyext_plugin::sprinter
  */
 static LY_ERR
 yangdata_schema_printer(struct lyspr_ctx *ctx, struct lysc_ext_instance *ext, ly_bool *flag)
diff --git a/src/plugins_types.c b/src/plugins_types.c
index 49d9490..12e41fe 100644
--- a/src/plugins_types.c
+++ b/src/plugins_types.c
@@ -148,7 +148,7 @@
 }
 
 API const struct lys_module *
-ly_type_identity_module(const struct ly_ctx *ctx, const struct lysc_node *ctx_node,
+lyplg_type_identity_module(const struct ly_ctx *ctx, const struct lysc_node *ctx_node,
         const char *prefix, size_t prefix_len, LY_PREFIX_FORMAT format, const void *prefix_data)
 {
     if (prefix_len) {
@@ -261,13 +261,13 @@
 }
 
 API const char *
-ly_type_get_prefix(const struct lys_module *mod, LY_PREFIX_FORMAT format, void *prefix_data)
+lyplg_type_get_prefix(const struct lys_module *mod, LY_PREFIX_FORMAT format, void *prefix_data)
 {
     return ly_get_prefix(mod, format, prefix_data);
 }
 
 API LY_ERR
-ly_type_compare_simple(const struct lyd_value *val1, const struct lyd_value *val2)
+lyplg_type_compare_simple(const struct lyd_value *val1, const struct lyd_value *val2)
 {
     if (val1->realtype != val2->realtype) {
         return LY_ENOT;
@@ -281,7 +281,7 @@
 }
 
 API const char *
-ly_type_print_simple(const struct lyd_value *value, LY_PREFIX_FORMAT UNUSED(format),
+lyplg_type_print_simple(const struct lyd_value *value, LY_PREFIX_FORMAT UNUSED(format),
         void *UNUSED(prefix_data), ly_bool *dynamic)
 {
     *dynamic = 0;
@@ -289,7 +289,7 @@
 }
 
 API LY_ERR
-ly_type_dup_simple(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
+lyplg_type_dup_simple(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
 {
     LY_CHECK_RET(lydict_insert(ctx, original->canonical, strlen(original->canonical), &dup->canonical));
     dup->ptr = original->ptr;
@@ -298,14 +298,14 @@
 }
 
 API void
-ly_type_free_simple(const struct ly_ctx *ctx, struct lyd_value *value)
+lyplg_type_free_simple(const struct ly_ctx *ctx, struct lyd_value *value)
 {
     lydict_remove(ctx, value->canonical);
     value->canonical = NULL;
 }
 
 API LY_ERR
-ly_type_parse_int(const char *datatype, int base, int64_t min, int64_t max, const char *value, size_t value_len,
+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)
 {
     LY_CHECK_ARG_RET(NULL, err, datatype, LY_EINVAL);
@@ -330,7 +330,7 @@
 }
 
 API LY_ERR
-ly_type_parse_uint(const char *datatype, int base, uint64_t max, const char *value, size_t value_len, uint64_t *ret,
+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)
 {
     LY_CHECK_ARG_RET(NULL, err, datatype, LY_EINVAL);
@@ -358,7 +358,7 @@
 }
 
 API LY_ERR
-ly_type_parse_dec64(uint8_t fraction_digits, const char *value, size_t value_len, int64_t *ret, struct ly_err_item **err)
+lyplg_type_parse_dec64(uint8_t fraction_digits, const char *value, size_t value_len, int64_t *ret, struct ly_err_item **err)
 {
     LY_ERR ret_val;
     char *valcopy = NULL;
@@ -442,7 +442,7 @@
         memset(&valcopy[len], '0', fraction_digits);
     }
 
-    ret_val = ly_type_parse_int("decimal64", LY_BASE_DEC, INT64_C(-9223372036854775807) - INT64_C(1), INT64_C(9223372036854775807),
+    ret_val = lyplg_type_parse_int("decimal64", LY_BASE_DEC, INT64_C(-9223372036854775807) - INT64_C(1), INT64_C(9223372036854775807),
             valcopy, len, &d, err);
     if (!ret_val && ret) {
         *ret = d;
@@ -453,7 +453,7 @@
 }
 
 API LY_ERR
-ly_type_validate_patterns(struct lysc_pattern **patterns, const char *str, size_t str_len, struct ly_err_item **err)
+lyplg_type_validate_patterns(struct lysc_pattern **patterns, const char *str, size_t str_len, struct ly_err_item **err)
 {
     int rc, match_opts;
     LY_ARRAY_COUNT_TYPE u;
@@ -500,7 +500,7 @@
 }
 
 API LY_ERR
-ly_type_validate_range(LY_DATA_TYPE basetype, struct lysc_range *range, int64_t value, const char *strval,
+lyplg_type_validate_range(LY_DATA_TYPE basetype, struct lysc_range *range, int64_t value, const char *strval,
         struct ly_err_item **err)
 {
     LY_ARRAY_COUNT_TYPE u;
@@ -561,7 +561,7 @@
 }
 
 API LY_ERR
-ly_type_prefix_data_new(const struct ly_ctx *ctx, const char *value, size_t value_len, LY_PREFIX_FORMAT format,
+lyplg_type_prefix_data_new(const struct ly_ctx *ctx, const char *value, size_t value_len, LY_PREFIX_FORMAT format,
         const void *prefix_data, LY_PREFIX_FORMAT *format_p, void **prefix_data_p)
 {
     LY_CHECK_ARG_RET(ctx, value, format_p, prefix_data_p, LY_EINVAL);
@@ -571,7 +571,7 @@
 }
 
 API LY_ERR
-ly_type_prefix_data_dup(const struct ly_ctx *ctx, LY_PREFIX_FORMAT format, const void *orig, void **dup)
+lyplg_type_prefix_data_dup(const struct ly_ctx *ctx, LY_PREFIX_FORMAT format, const void *orig, void **dup)
 {
     LY_CHECK_ARG_RET(NULL, dup, LY_EINVAL);
 
@@ -584,7 +584,7 @@
 }
 
 API void
-ly_type_prefix_data_free(LY_PREFIX_FORMAT format, void *prefix_data)
+lyplg_type_prefix_data_free(LY_PREFIX_FORMAT format, void *prefix_data)
 {
     ly_free_prefix_data(format, prefix_data);
 }
@@ -607,7 +607,7 @@
 }
 
 API LY_ERR
-ly_type_check_hints(uint32_t hints, const char *value, size_t value_len, LY_DATA_TYPE type, int *base, struct ly_err_item **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)
 {
     LY_CHECK_ARG_RET(NULL, value || !value_len, err, LY_EINVAL);
 
@@ -675,7 +675,7 @@
 }
 
 API LY_ERR
-ly_type_lypath_new(const struct ly_ctx *ctx, const char *value, size_t value_len, uint32_t options,
+lyplg_type_lypath_new(const struct ly_ctx *ctx, const char *value, size_t value_len, uint32_t options,
         LY_PREFIX_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)
 {
@@ -707,7 +707,7 @@
         goto cleanup;
     }
 
-    if (options & LY_TYPE_STORE_IMPLEMENT) {
+    if (options & LYPLG_TYPE_STORE_IMPLEMENT) {
         /* implement all prefixes */
         LY_CHECK_GOTO(ret = lys_compile_expr_implement(ctx, exp, format, prefix_data, 1, unres, NULL), cleanup);
     }
@@ -731,19 +731,19 @@
 }
 
 API void
-ly_type_lypath_free(const struct ly_ctx *ctx, struct ly_path *path)
+lyplg_type_lypath_free(const struct ly_ctx *ctx, struct ly_path *path)
 {
     ly_path_free(ctx, path);
 }
 
 API LY_ERR
-ly_type_make_implemented(struct lys_module *mod, const char **features, struct lys_glob_unres *unres)
+lyplg_type_make_implemented(struct lys_module *mod, const char **features, struct lys_glob_unres *unres)
 {
     return lys_set_implemented_r(mod, features, unres);
 }
 
 API LY_ERR
-ly_type_identity_isderived(struct lysc_ident *base, struct lysc_ident *der)
+lyplg_type_identity_isderived(struct lysc_ident *base, struct lysc_ident *der)
 {
     LY_ARRAY_COUNT_TYPE u;
 
@@ -751,7 +751,7 @@
         if (der == base->derived[u]) {
             return LY_SUCCESS;
         }
-        if (!ly_type_identity_isderived(base->derived[u], der)) {
+        if (!lyplg_type_identity_isderived(base->derived[u], der)) {
             return LY_SUCCESS;
         }
     }
@@ -759,7 +759,7 @@
 }
 
 API LY_ERR
-ly_type_resolve_leafref(const struct lysc_type_leafref *lref, const struct lyd_node *node, struct lyd_value *value,
+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 lyd_node **target, char **errmsg)
 {
     LY_ERR ret;
diff --git a/src/plugins_types.h b/src/plugins_types.h
index ee50a51..4e16014 100644
--- a/src/plugins_types.h
+++ b/src/plugins_types.h
@@ -69,7 +69,7 @@
  * ::ly_err_item error structure(s) describing the detected error(s) (helper functions ::ly_err_new() and ::ly_err_free()
  * are available).
  *
- * The main functionality is provided via ::ly_type_store_clb callback responsible for canonizing and storing
+ * The main functionality is provided via ::lyplg_type_store_clb callback responsible for canonizing and storing
  * provided string representation of the value in specified format (XML and JSON supported). Valid value is stored in
  * ::lyd_value structure - its union allows to store data as one of the predefined type or in a custom form behind
  * the ptr member (void *) of ::lyd_value structure. The callback is also responsible for storing canonized string
@@ -77,8 +77,8 @@
  * representation is stored. In case there are any differences between the representation in specific input types, the plugin
  * is supposed to store the value in JSON representation - typically, the difference is in prefix representation and JSON
  * format use directly the module names as prefixes. Optionally, in case the type requires some validation referencing other
- * entities in the data tree, the ::ly_type_validate_clb can be implemented. The stored value can be printed into the
- * required format via ::ly_type_print_clb implementation.
+ * entities in the data tree, the ::lyplg_type_validate_clb can be implemented. The stored value can be printed into the
+ * required format via ::lyplg_type_print_clb implementation.
  */
 
 /**
@@ -128,10 +128,10 @@
 /**
  * @brief Check that the type is suitable for the parser's hints (if any) in the specified format
  *
- * Use only in implementations of ::ly_type_store_clb which provide all the necessary parameters for this function.
+ * Use only in implementations of ::lyplg_type_store_clb which provide all the necessary parameters for this function.
  *
  * @param[in] hints Bitmap of [value hints](@ref lydvalhints) of all the allowed value types provided by parsers
- *            to ::ly_type_store_clb.
+ *            to ::lyplg_type_store_clb.
  * @param[in] value Lexical representation of the value to be stored.
  * @param[in] value_len Length (number of bytes) of the given \p value.
  * @param[in] type Expected base type of the @p value by the caller.
@@ -140,56 +140,56 @@
  * @param[out] err Pointer to store error information in case of failure.
  * @return LY_ERR value
  */
-LY_ERR ly_type_check_hints(uint32_t hints, const char *value, size_t value_len, LY_DATA_TYPE type, int *base,
+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);
 
 /**
  * @brief Get the corresponding module for the identity value.
  *
- * Use only in implementations of ::ly_type_store_clb which provide all the necessary parameters for this function.
+ * Use only in implementations of ::lyplg_type_store_clb which provide all the necessary parameters for this function.
  *
  * @param[in] ctx libyang context.
  * @param[in] ctx_node Schema node where the value is instantiated to determine the module in case of unprefixed value
  * in specific @p format.
- * @param[in] prefix Prefix to resolve - identified beginning of a prefix in ::ly_type_store_clb's value parameter.
+ * @param[in] prefix Prefix to resolve - identified beginning of a prefix in ::lyplg_type_store_clb's value parameter.
  * @param[in] prefix_len Length of @p prefix.
- * @param[in] format Format of the prefix (::ly_type_store_clb's format parameter).
- * @param[in] prefix_data Format-specific data (::ly_type_store_clb's prefix_data parameter).
+ * @param[in] format Format of the prefix (::lyplg_type_store_clb's format parameter).
+ * @param[in] prefix_data Format-specific data (::lyplg_type_store_clb's prefix_data parameter).
  * @return Resolved prefix module,
  * @return NULL otherwise.
  */
-const struct lys_module *ly_type_identity_module(const struct ly_ctx *ctx, const struct lysc_node *ctx_node,
+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_PREFIX_FORMAT format, const void *prefix_data);
 
 /**
  * @brief Implement a module (just like ::lys_set_implemented()), but keep maintaining unresolved items.
  *
- * Use only in implementations of ::ly_type_store_clb which provide all the necessary parameters for this function.
+ * Use only in implementations of ::lyplg_type_store_clb which provide all the necessary parameters for this function.
  *
  * @param[in] mod Module to implement.
  * @param[in] features Array of features to enable.
  * @param[in,out] unres Global unres to add to.
  * @return LY_ERR value.
  */
-LY_ERR ly_type_make_implemented(struct lys_module *mod, const char **features, struct lys_glob_unres *unres);
+LY_ERR lyplg_type_make_implemented(struct lys_module *mod, const char **features, struct lys_glob_unres *unres);
 
 /**
  * @brief Get format-specific prefix for a module.
  *
- * Use only in implementations of ::ly_type_print_clb which provide all the necessary parameters for this function.
+ * Use only in implementations of ::lyplg_type_print_clb which provide all the necessary parameters for this function.
  *
  * @param[in] mod Module whose prefix to get - the module somehow connected with the value to print.
- * @param[in] format Format of the prefix (::ly_type_print_clb's format parameter).
- * @param[in] prefix_data Format-specific data (::ly_type_print_clb's prefix_data parameter).
+ * @param[in] format Format of the prefix (::lyplg_type_print_clb's format parameter).
+ * @param[in] prefix_data Format-specific data (::lyplg_type_print_clb's prefix_data parameter).
  * @return Module's prefix to print.
  * @return NULL on error.
  */
-const char *ly_type_get_prefix(const struct lys_module *mod, LY_PREFIX_FORMAT format, void *prefix_data);
+const char *lyplg_type_get_prefix(const struct lys_module *mod, LY_PREFIX_FORMAT format, void *prefix_data);
 
 /**
  * @brief Store used prefixes in a string into an internal libyang structure used in ::lyd_value.
  *
- * Use only in implementations of ::ly_type_store_clb which provide all the necessary parameters for this function.
+ * Use only in implementations of ::lyplg_type_store_clb which provide all the necessary parameters for this function.
  *
  * If @p prefix_data_p are non-NULL, they are treated as valid according to the @p format_p and new possible
  * prefixes are simply added. This way it is possible to store prefix data for several strings together.
@@ -198,17 +198,17 @@
  * @param[in] value Value string to be parsed.
  * @param[in] value_len Length of the @p value string.
  * @param[in] format Format of the prefixes in the value.
- * @param[in] prefix_data Format-specific data for resolving any prefixes (see ::ly_resolve_prefix).
+ * @param[in] prefix_data Format-specific data for resolving any prefixes (see ly_resolve_prefix()).
  * @param[in,out] format_p Resulting format of the prefixes.
  * @param[in,out] prefix_data_p Resulting prefix data for the value in format @p format_p.
  * @return LY_ERR value.
  */
-LY_ERR ly_type_prefix_data_new(const struct ly_ctx *ctx, const char *value, size_t value_len, LY_PREFIX_FORMAT format,
+LY_ERR lyplg_type_prefix_data_new(const struct ly_ctx *ctx, const char *value, size_t value_len, LY_PREFIX_FORMAT format,
         const void *prefix_data, LY_PREFIX_FORMAT *format_p, void **prefix_data_p);
 /*
  * @brief Duplicate prefix data.
  *
- * Use only in implementations of ::ly_type_store_clb which provide all the necessary parameters for this function.
+ * Use only in implementations of ::lyplg_type_store_clb which provide all the necessary parameters for this function.
  *
  * @param[in] ctx libyang context.
  * @param[in] format Format of the prefixes in the value.
@@ -216,29 +216,29 @@
  * @param[out] dup Duplicated prefix data.
  * @return LY_ERR value.
  */
-LY_ERR ly_type_prefix_data_dup(const struct ly_ctx *ctx, LY_PREFIX_FORMAT format, const void *orig, void **dup);
+LY_ERR lyplg_type_prefix_data_dup(const struct ly_ctx *ctx, LY_PREFIX_FORMAT format, const void *orig, void **dup);
 
 /**
  * @brief Free internal prefix data.
  *
- * Use only in implementations of ::ly_type_store_clb which provide all the necessary parameters for this function.
+ * Use only in implementations of ::lyplg_type_store_clb which provide all the necessary parameters for this function.
  *
  * @param[in] format Format of the prefixes.
  * @param[in] prefix_data Format-specific data to free.
  */
-void ly_type_prefix_data_free(LY_PREFIX_FORMAT format, void *prefix_data);
+void lyplg_type_prefix_data_free(LY_PREFIX_FORMAT format, void *prefix_data);
 
 /**
  * @brief Helper function to create internal schema path representation for instance-identifier value representation.
  *
- * Use only in implementations of ::ly_type_store_clb which provide all the necessary parameters for this function.
+ * Use only in implementations of ::lyplg_type_store_clb which provide all the necessary parameters for this function.
  *
  * @param[in] ctx libyang Context
  * @param[in] value Lexical representation of the value to be stored.
  * @param[in] value_len Length (number of bytes) of the given \p value.
  * @param[in] options [Type plugin store options](@ref plugintypestoreopts).
  * @param[in] format Input format of the value.
- * @param[in] prefix_data Format-specific data for resolving any prefixes (see ::ly_type_store_resolve_prefix).
+ * @param[in] prefix_data Format-specific data for resolving any prefixes (see ly_resolve_prefix()).
  * @param[in] ctx_node The @p value schema context node.
  * @param[in,out] unres Global unres structure for newly implemented modules.
  * @param[out] path Pointer to store the created structure representing the schema path from the @p value.
@@ -246,33 +246,33 @@
  * @return LY_SUCCESS on success,
  * @return LY_ERR value on error.
  */
-LY_ERR ly_type_lypath_new(const struct ly_ctx *ctx, const char *value, size_t value_len, uint32_t options,
+LY_ERR lyplg_type_lypath_new(const struct ly_ctx *ctx, const char *value, size_t value_len, uint32_t options,
         LY_PREFIX_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);
 
 /**
  * @brief Free ly_path structure used by instanceid value representation.
  *
- * The ly_path representation can be created by ::ly_type_lypath_new().
+ * The ly_path representation can be created by ::lyplg_type_lypath_new().
  *
  * @param[in] ctx libyang context.
  * @param[in] path The structure ([sized array](@ref sizedarrays)) to free.
  */
-void ly_type_lypath_free(const struct ly_ctx *ctx, struct ly_path *path);
+void lyplg_type_lypath_free(const struct ly_ctx *ctx, struct ly_path *path);
 
 /**
  * @defgroup plugintypestoreopts Type store callback options.
  *
- * Options applicable to ::ly_type_store_clb().
+ * Options applicable to ::lyplg_type_store_clb().
  *
  * @{
  */
-#define LY_TYPE_STORE_DYNAMIC   0x01 /**< String value was dynamically allocated and is supposed to be freed or
-                                          directly inserted into the context's dictionary (e.g. in case of canonization).
-                                          In any case, the caller of the callback does not free the provided string
-                                          value after calling the type's store callback with this option */
-#define LY_TYPE_STORE_IMPLEMENT 0x02 /**< If a foreign module is needed to be implemented to successfully instantiate
-                                          the value, make the module implemented. */
+#define LYPLG_TYPE_STORE_DYNAMIC   0x01 /**< String value was dynamically allocated and is supposed to be freed or
+                                             directly inserted into the context's dictionary (e.g. in case of canonization).
+                                             In any case, the caller of the callback does not free the provided string
+                                             value after calling the type's store callback with this option */
+#define LYPLG_TYPE_STORE_IMPLEMENT 0x02 /**< If a foreign module is needed to be implemented to successfully instantiate
+                                             the value, make the module implemented. */
 /** @} plugintypestoreopts */
 
 /**
@@ -292,7 +292,7 @@
  * @param[in] value_len Length (number of bytes) of the given \p value.
  * @param[in] options [Type plugin store options](@ref plugintypestoreopts).
  * @param[in] format Input format of the value.
- * @param[in] prefix_data Format-specific data for resolving any prefixes (see ::ly_type_store_resolve_prefix).
+ * @param[in] prefix_data Format-specific data for resolving any prefixes (see ly_resolve_prefix()).
  * @param[in] hints Bitmap of [value hints](@ref lydvalhints) of all the allowed value types.
  * @param[in] ctx_node The @p value schema context node.
  * @param[out] storage Storage for the value in the type's specific encoding. All the members should be filled by the plugin.
@@ -300,10 +300,10 @@
  * @param[out] err Optionally provided error information in case of failure. If not provided to the caller, a generic
  *             error message is prepared instead. The error structure can be created by ::ly_err_new().
  * @return LY_SUCCESS on success,
- * @return LY_EINCOMPLETE in case the ::ly_type_validate_clb should be called to finish value validation in data,
+ * @return LY_EINCOMPLETE in case the ::lyplg_type_validate_clb should be called to finish value validation in data,
  * @return LY_ERR value on error.
  */
-typedef LY_ERR (*ly_type_store_clb)(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value,
+typedef LY_ERR (*lyplg_type_store_clb)(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value,
         size_t value_len, uint32_t options, LY_PREFIX_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);
 
@@ -311,20 +311,20 @@
  * @brief Callback to validate the stored value in data.
  *
  * This callback is optional for types that can only be validated in a data tree. It must be called and succeed
- * in case the ::ly_type_store_clb callback returned ::LY_EINCOMPLETE for the value to be valid. However, this
+ * in case the ::lyplg_type_store_clb callback returned ::LY_EINCOMPLETE for the value to be valid. However, this
  * callback can be called even in other cases (such as separate/repeated validation).
  *
  * @param[in] ctx libyang Context
  * @param[in] type Original type of the value (not necessarily the stored one) being validated.
  * @param[in] ctx_node The value data context node for validation.
  * @param[in] tree External data tree (e.g. when validating RPC/Notification) with possibly referenced data.
- * @param[in,out] storage Storage of the value successfully filled by ::ly_type_store_clb. May be modified.
+ * @param[in,out] storage Storage of the value successfully filled by ::lyplg_type_store_clb. May be modified.
  * @param[out] err Optionally provided error information in case of failure. If not provided to the caller, a generic
  *             error message is prepared instead. The error structure can be created by ::ly_err_new().
  * @return LY_SUCCESS on success,
  * @return LY_ERR value on error.
  */
-typedef LY_ERR (*ly_type_validate_clb)(const struct ly_ctx *ctx, const struct lysc_type *type,
+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);
 
 /**
@@ -338,7 +338,7 @@
  * @return LY_SUCCESS if values are same (according to the type's definition of being same).
  * @return LY_ENOT if values differ.
  */
-typedef LY_ERR (*ly_type_compare_clb)(const struct lyd_value *val1, const struct lyd_value *val2);
+typedef LY_ERR (*lyplg_type_compare_clb)(const struct lyd_value *val1, const struct lyd_value *val2);
 
 /**
  * @brief Callback to getting the canonical value of the data stored in @p value.
@@ -346,14 +346,14 @@
  * @param[in] value Value to print.
  * @param[in] format Format in which the data are supposed to be printed.
  *            Only 2 formats are currently implemented: LYD_XML and LYD_JSON.
- * @param[in] prefix_data Format-specific data for getting any prefixes (see ::ly_type_print_get_prefix()).
+ * @param[in] prefix_data Format-specific data for getting any prefixes (see ::lyplg_type_get_prefix()).
  * @param[out] dynamic Flag if the returned string is dynamically allocated. In such a case the caller is responsible
  *            for freeing it.
  * @return String with the value of @p value in specified @p format. According to the returned @p dynamic flag, caller
  *         can be responsible for freeing allocated memory.
  * @return NULL in case of error.
  */
-typedef const char *(*ly_type_print_clb)(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data,
+typedef const char *(*lyplg_type_print_clb)(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data,
         ly_bool *dynamic);
 
 /**
@@ -366,17 +366,17 @@
  * @return LY_SUCCESS after successful duplication.
  * @return LY_ERR value on error.
  */
-typedef LY_ERR (*ly_type_dup_clb)(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup);
+typedef LY_ERR (*lyplg_type_dup_clb)(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup);
 
 /**
- * @brief Callback for freeing the user type values stored by ::ly_type_store_clb.
+ * @brief Callback for freeing the user type values stored by ::lyplg_type_store_clb.
  *
  * Note that this callback is responsible also for freeing the canonized member in the @p value.
  *
  * @param[in] ctx libyang ctx to enable correct manipulation with values that are in the dictionary.
- * @param[in,out] value Value structure to free the data stored there by the plugin's ::ly_type_store_clb callback
+ * @param[in,out] value Value structure to free the data stored there by the plugin's ::lyplg_type_store_clb callback
  */
-typedef void (*ly_type_free_clb)(const struct ly_ctx *ctx, struct lyd_value *value);
+typedef void (*lyplg_type_free_clb)(const struct ly_ctx *ctx, struct lyd_value *value);
 
 /**
  * @brief Hold type-specific functions for various operations with the data values.
@@ -388,12 +388,12 @@
  */
 struct lyplg_type {
     LY_DATA_TYPE type;               /**< implemented type, use ::LY_TYPE_UNKNOWN for derived data types */
-    ly_type_store_clb store;         /**< store and canonize the value in the type-specific way */
-    ly_type_validate_clb validate;   /**< optional, validate the value in the type-specific way in data */
-    ly_type_compare_clb compare;     /**< comparison callback to compare 2 values of the same type */
-    ly_type_print_clb print;         /**< printer callback to get string representing the value */
-    ly_type_dup_clb duplicate;       /**< data duplication callback */
-    ly_type_free_clb free;           /**< optional function to free the type-spceific way stored value */
+    lyplg_type_store_clb store;         /**< store and canonize the value in the type-specific way */
+    lyplg_type_validate_clb validate;   /**< optional, validate the value in the type-specific way in data */
+    lyplg_type_compare_clb compare;     /**< comparison callback to compare 2 values of the same type */
+    lyplg_type_print_clb print;         /**< printer callback to get string representing the value */
+    lyplg_type_dup_clb duplicate;       /**< data duplication callback */
+    lyplg_type_free_clb free;           /**< optional function to free the type-spceific way stored value */
     const char *id;                  /**< Plugin identification (mainly for distinguish incompatible versions when used by external tools) */
 };
 
@@ -413,27 +413,27 @@
 
 /**
  * @brief Generic simple comparison callback checking the canonical value.
- * Implementation of the ::ly_type_compare_clb.
+ * Implementation of the ::lyplg_type_compare_clb.
  */
-LY_ERR ly_type_compare_simple(const struct lyd_value *val1, const struct lyd_value *val2);
+LY_ERR lyplg_type_compare_simple(const struct lyd_value *val1, const struct lyd_value *val2);
 
 /**
  * @brief Generic simple printer callback of the canonized value.
- * Implementation of the ::ly_type_print_clb.
+ * Implementation of the ::lyplg_type_print_clb.
  */
-const char *ly_type_print_simple(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data, ly_bool *dynamic);
+const char *lyplg_type_print_simple(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data, ly_bool *dynamic);
 
 /**
  * @brief Generic simple duplication callback.
- * Implementation of the ::ly_type_dup_clb.
+ * Implementation of the ::lyplg_type_dup_clb.
  */
-LY_ERR ly_type_dup_simple(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup);
+LY_ERR lyplg_type_dup_simple(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup);
 
 /**
  * @brief Generic cleanup callback freeing only the canonized value in ::lyd_value.canonical.
- * Simple implementation of the ::ly_type_free_clb.
+ * Simple implementation of the ::lyplg_type_free_clb.
  */
-void ly_type_free_simple(const struct ly_ctx *ctx, struct lyd_value *value);
+void lyplg_type_free_simple(const struct ly_ctx *ctx, struct lyd_value *value);
 
 /*
  * Binary built-in type functions
@@ -441,9 +441,9 @@
 
 /**
  * @brief Validate, canonize and store value of the YANG built-in binary type.
- * Implementation of the ly_type_store_clb.
+ * Implementation of the ::lyplg_type_store_clb.
  */
-LY_ERR ly_type_store_binary(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+LY_ERR lyplg_type_store_binary(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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);
 
@@ -453,23 +453,23 @@
 
 /**
  * @brief Validate, canonize and store value of the YANG built-in bits type.
- * Implementation of the ly_type_store_clb.
+ * Implementation of the ::lyplg_type_store_clb.
  */
-LY_ERR ly_type_store_bits(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+LY_ERR lyplg_type_store_bits(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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);
 
 /**
  * @brief Duplication callback of the bits values.
- * Implementation of the ly_type_dup_clb.
+ * Implementation of the ::lyplg_type_dup_clb.
  */
-LY_ERR ly_type_dup_bits(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup);
+LY_ERR lyplg_type_dup_bits(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup);
 
 /**
  * @brief Free value of the YANG built-in bits type.
- * Implementation of the ly_type_free_clb.
+ * Implementation of the ::lyplg_type_free_clb.
  */
-void ly_type_free_bits(const struct ly_ctx *ctx, struct lyd_value *value);
+void lyplg_type_free_bits(const struct ly_ctx *ctx, struct lyd_value *value);
 
 /*
  * Boolean built-in type functions
@@ -477,9 +477,9 @@
 
 /**
  * @brief Validate and store value of the YANG built-in boolean type.
- * Implementation of the ly_type_store_clb.
+ * Implementation of the ::lyplg_type_store_clb.
  */
-LY_ERR ly_type_store_boolean(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+LY_ERR lyplg_type_store_boolean(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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);
 
@@ -489,9 +489,9 @@
 
 /**
  * @brief Validate, canonize and store value of the YANG built-in decimal64 types.
- * Implementation of the ly_type_store_clb.
+ * Implementation of the ::lyplg_type_store_clb.
  */
-LY_ERR ly_type_store_decimal64(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+LY_ERR lyplg_type_store_decimal64(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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);
 
@@ -501,17 +501,17 @@
 
 /**
  * @brief Validate and store value of the YANG built-in empty type.
- * Implementation of the ly_type_store_clb.
+ * Implementation of the ::lyplg_type_store_clb.
  */
-LY_ERR ly_type_store_empty(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+LY_ERR lyplg_type_store_empty(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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);
 
 /**
  * @brief Comparison callback for built-in empty type.
- * Implementation of the ly_type_compare_clb.
+ * Implementation of the ::lyplg_type_compare_clb.
  */
-LY_ERR ly_type_compare_empty(const struct lyd_value *val1, const struct lyd_value *val2);
+LY_ERR lyplg_type_compare_empty(const struct lyd_value *val1, const struct lyd_value *val2);
 
 /*
  * Enumeration built-in type functions
@@ -519,9 +519,9 @@
 
 /**
  * @brief Validate, canonize and store value of the YANG built-in enumeration type.
- * Implementation of the ly_type_store_clb.
+ * Implementation of the ::lyplg_type_store_clb.
  */
-LY_ERR ly_type_store_enum(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+LY_ERR lyplg_type_store_enum(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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);
 
@@ -531,23 +531,23 @@
 
 /**
  * @brief Validate, canonize and store value of the YANG built-in identiytref type.
- * Implementation of the ly_type_store_clb.
+ * Implementation of the ::lyplg_type_store_clb.
  */
-LY_ERR ly_type_store_identityref(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+LY_ERR lyplg_type_store_identityref(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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);
 
 /**
  * @brief Comparison callback for built-in identityref type.
- * Implementation of the ly_type_compare_clb.
+ * Implementation of the ::lyplg_type_compare_clb.
  */
-LY_ERR ly_type_compare_identityref(const struct lyd_value *val1, const struct lyd_value *val2);
+LY_ERR lyplg_type_compare_identityref(const struct lyd_value *val1, const struct lyd_value *val2);
 
 /**
  * @brief Printer callback printing identityref value.
- * Implementation of the ly_type_print_clb.
+ * Implementation of the ::lyplg_type_print_clb.
  */
-const char *ly_type_print_identityref(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data,
+const char *lyplg_type_print_identityref(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data,
         ly_bool *dynamic);
 
 /*
@@ -556,43 +556,43 @@
 
 /**
  * @brief Validate and store value of the YANG built-in instance-identifier type.
- * Implementation of the ly_type_store_clb.
+ * Implementation of the ::lyplg_type_store_clb.
  */
-LY_ERR ly_type_store_instanceid(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+LY_ERR lyplg_type_store_instanceid(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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);
 
 /**
  * @brief Comparison callback checking the instance-identifier value.
- * Implementation of the ly_type_compare_clb.
+ * Implementation of the ::lyplg_type_compare_clb.
  */
-LY_ERR ly_type_compare_instanceid(const struct lyd_value *val1, const struct lyd_value *val2);
+LY_ERR lyplg_type_compare_instanceid(const struct lyd_value *val1, const struct lyd_value *val2);
 
 /**
  * @brief Printer callback printing the instance-identifier value.
- * Implementation of the ly_type_print_clb.
+ * Implementation of the ::lyplg_type_print_clb.
  */
-const char *ly_type_print_instanceid(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data,
+const char *lyplg_type_print_instanceid(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data,
         ly_bool *dynamic);
 
 /**
  * @brief Duplication callback of the instance-identifier values.
- * Implementation of the ly_type_dup_clb.
+ * Implementation of the ::lyplg_type_dup_clb.
  */
-LY_ERR ly_type_dup_instanceid(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup);
+LY_ERR lyplg_type_dup_instanceid(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup);
 
 /**
  * @brief Validate value of the YANG built-in instance-identifier type.
- * Implementation of the ly_type_validate_clb.
+ * Implementation of the ::lyplg_type_validate_clb.
  */
-LY_ERR ly_type_validate_instanceid(const struct ly_ctx *ctx, const struct lysc_type *type, const struct lyd_node *ctx_node,
+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);
 
 /**
  * @brief Free value of the YANG built-in instance-identifier types.
- * Implementation of the ly_type_free_clb.
+ * Implementation of the ::lyplg_type_free_clb.
  */
-void ly_type_free_instanceid(const struct ly_ctx *ctx, struct lyd_value *value);
+void lyplg_type_free_instanceid(const struct ly_ctx *ctx, struct lyd_value *value);
 
 /*
  * Integer built-in types functions
@@ -600,17 +600,17 @@
 
 /**
  * @brief Validate, canonize and store value of the YANG built-in signed integer types.
- * Implementation of the ly_type_store_clb.
+ * Implementation of the ::lyplg_type_store_clb.
  */
-LY_ERR ly_type_store_int(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+LY_ERR lyplg_type_store_int(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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);
 
 /**
  * @brief Validate and canonize value of the YANG built-in unsigned integer types.
- * Implementation of the ly_type_store_clb.
+ * Implementation of the ::lyplg_type_store_clb.
  */
-LY_ERR ly_type_store_uint(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+LY_ERR lyplg_type_store_uint(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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);
 
@@ -620,43 +620,43 @@
 
 /**
  * @brief Validate, canonize and store value of the YANG built-in leafref type.
- * Implementation of the ly_type_store_clb.
+ * Implementation of the ::lyplg_type_store_clb.
  */
-LY_ERR ly_type_store_leafref(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+LY_ERR lyplg_type_store_leafref(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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);
 
 /**
  * @brief Comparison callback checking the leafref value.
- * Implementation of the ly_type_compare_clb.
+ * Implementation of the ::lyplg_type_compare_clb.
  */
-LY_ERR ly_type_compare_leafref(const struct lyd_value *val1, const struct lyd_value *val2);
+LY_ERR lyplg_type_compare_leafref(const struct lyd_value *val1, const struct lyd_value *val2);
 
 /**
  * @brief Printer callback printing the leafref value.
- * Implementation of the ly_type_print_clb.
+ * Implementation of the ::lyplg_type_print_clb.
  */
-const char *ly_type_print_leafref(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data,
+const char *lyplg_type_print_leafref(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data,
         ly_bool *dynamic);
 
 /**
  * @brief Duplication callback of the leafref values.
- * Implementation of the ly_type_dup_clb.
+ * Implementation of the ::lyplg_type_dup_clb.
  */
-LY_ERR ly_type_dup_leafref(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup);
+LY_ERR lyplg_type_dup_leafref(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup);
 
 /**
  * @brief Validate value of the YANG built-in leafref type.
- * Implementation of the ly_type_validate_clb.
+ * Implementation of the ::lyplg_type_validate_clb.
  */
-LY_ERR ly_type_validate_leafref(const struct ly_ctx *ctx, const struct lysc_type *type, const struct lyd_node *ctx_node,
+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);
 
 /**
  * @brief Free value of the YANG built-in leafref types.
- * Implementation of the ly_type_free_clb.
+ * Implementation of the ::lyplg_type_free_clb.
  */
-void ly_type_free_leafref(const struct ly_ctx *ctx, struct lyd_value *value);
+void lyplg_type_free_leafref(const struct ly_ctx *ctx, struct lyd_value *value);
 
 /*
  * String built-in type functions
@@ -664,9 +664,9 @@
 
 /**
  * @brief Validate and store value of the YANG built-in string type.
- * Implementation of the ::ly_type_store_clb.
+ * Implementation of the ::lyplg_type_store_clb.
  */
-LY_ERR ly_type_store_string(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+LY_ERR lyplg_type_store_string(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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);
 
@@ -676,43 +676,43 @@
 
 /**
  * @brief Validate, canonize and store value of the YANG built-in union type.
- * Implementation of the ly_type_store_clb.
+ * Implementation of the ::lyplg_type_store_clb.
  */
-LY_ERR ly_type_store_union(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+LY_ERR lyplg_type_store_union(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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);
 
 /**
  * @brief Comparison callback checking the union value.
- * Implementation of the ly_type_compare_clb.
+ * Implementation of the ::lyplg_type_compare_clb.
  */
-LY_ERR ly_type_compare_union(const struct lyd_value *val1, const struct lyd_value *val2);
+LY_ERR lyplg_type_compare_union(const struct lyd_value *val1, const struct lyd_value *val2);
 
 /**
  * @brief Printer callback printing the union value.
- * Implementation of the ly_type_print_clb.
+ * Implementation of the ::lyplg_type_print_clb.
  */
-const char *ly_type_print_union(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data,
+const char *lyplg_type_print_union(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data,
         ly_bool *dynamic);
 
 /**
  * @brief Duplication callback of the union values.
- * Implementation of the ly_type_dup_clb.
+ * Implementation of the ::lyplg_type_dup_clb.
  */
-LY_ERR ly_type_dup_union(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup);
+LY_ERR lyplg_type_dup_union(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup);
 
 /**
  * @brief Validate value of the YANG built-in union type.
- * Implementation of the ly_type_validate_clb.
+ * Implementation of the ::lyplg_type_validate_clb.
  */
-LY_ERR ly_type_validate_union(const struct ly_ctx *ctx, const struct lysc_type *type, const struct lyd_node *ctx_node,
+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);
 
 /**
  * @brief Free value of the YANG built-in union types.
- * Implementation of the ly_type_free_clb.
+ * Implementation of the ::lyplg_type_free_clb.
  */
-void ly_type_free_union(const struct ly_ctx *ctx, struct lyd_value *value);
+void lyplg_type_free_union(const struct ly_ctx *ctx, struct lyd_value *value);
 
 /*
  * Other supporting functions
@@ -732,7 +732,7 @@
  * @param[out] err Error information in case of failure. The error structure can be freed by ::ly_err_free().
  * @return LY_ERR value according to the result of the parsing and validation.
  */
-LY_ERR ly_type_parse_int(const char *datatype, int base, int64_t min, int64_t max, const char *value, size_t value_len,
+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);
 
 /**
@@ -748,7 +748,7 @@
  * @param[out] err Error information in case of failure. The error structure can be freed by ::ly_err_free().
  * @return LY_ERR value according to the result of the parsing and validation.
  */
-LY_ERR ly_type_parse_uint(const char *datatype, int base, uint64_t max, const char *value, size_t value_len,
+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);
 
 /**
@@ -762,7 +762,7 @@
  * @param[out] err Error information in case of failure. The error structure can be freed by ::ly_err_free().
  * @return LY_ERR value according to the result of the parsing and validation.
  */
-LY_ERR ly_type_parse_dec64(uint8_t fraction_digits, const char *value, size_t value_len, int64_t *ret, struct ly_err_item **err);
+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);
 
 /**
  * @brief Decide if the @p derived identity is derived from (based on) the @p base identity.
@@ -772,7 +772,7 @@
  * @return LY_SUCCESS if @p derived IS based on the @p base identity.
  * @return LY_ENOTFOUND if @p derived IS NOT not based on the @p base identity.
  */
-LY_ERR ly_type_identity_isderived(struct lysc_ident *base, struct lysc_ident *derived);
+LY_ERR lyplg_type_identity_isderived(struct lysc_ident *base, struct lysc_ident *derived);
 
 /**
  * @brief Data type validator for a range/length-restricted values.
@@ -784,7 +784,7 @@
  * @param[out] err Error information in case of failure. The error structure can be freed by ::ly_err_free().
  * @return LY_ERR value according to the result of the validation.
  */
-LY_ERR ly_type_validate_range(LY_DATA_TYPE basetype, struct lysc_range *range, int64_t value, const char *strval,
+LY_ERR lyplg_type_validate_range(LY_DATA_TYPE basetype, struct lysc_range *range, int64_t value, const char *strval,
         struct ly_err_item **err);
 
 /**
@@ -799,7 +799,7 @@
  * @return LY_EVALID when @p does not match any of the patterns.
  * @return LY_ESYS in case of PCRE2 error.
  */
-LY_ERR ly_type_validate_patterns(struct lysc_pattern **patterns, const char *str, size_t str_len, struct ly_err_item **err);
+LY_ERR lyplg_type_validate_patterns(struct lysc_pattern **patterns, const char *str, size_t str_len, struct ly_err_item **err);
 
 /**
  * @brief Find leafref target in data.
@@ -812,7 +812,7 @@
  * @param[out] errmsg Error message in case of error.
  * @return LY_ERR value.
  */
-LY_ERR ly_type_resolve_leafref(const struct lysc_type_leafref *lref, const struct lyd_node *node, struct lyd_value *value,
+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 lyd_node **target, char **errmsg);
 
 /** @} types */
diff --git a/src/plugins_types_binary.c b/src/plugins_types_binary.c
index ea787d5..f7158ad 100644
--- a/src/plugins_types_binary.c
+++ b/src/plugins_types_binary.c
@@ -29,7 +29,7 @@
 #include "plugins_internal.h" /* LY_TYPE_*_STR */
 
 API LY_ERR
-ly_type_store_binary(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+lyplg_type_store_binary(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_FORMAT UNUSED(format), void *UNUSED(prefix_data), uint32_t hints,
         const struct lysc_node *UNUSED(ctx_node), struct lyd_value *storage, struct lys_glob_unres *UNUSED(unres),
         struct ly_err_item **err)
@@ -43,7 +43,7 @@
     *err = NULL;
 
     /* check hints */
-    ret = ly_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
+    ret = lyplg_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
     LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
 
     /* validate characters and remember the number of octets for length validation */
@@ -104,7 +104,7 @@
     /* check if value meets the type requirments */
     if (type_bin->length) {
         const uint32_t value_length = ((base64_count + base64_terminated) / 4) * 3 - base64_terminated;
-        ret = ly_type_validate_range(LY_TYPE_BINARY, type_bin->length, value_length, value, err);
+        ret = lyplg_type_validate_range(LY_TYPE_BINARY, type_bin->length, value_length, value, err);
         LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
     }
 
@@ -119,7 +119,7 @@
     storage->realtype = type;
 
 cleanup:
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         free((char *)value);
     }
     return ret;
@@ -140,12 +140,12 @@
 
         .plugin.id = "libyang 2 - binary, version 1",
         .plugin.type = LY_TYPE_BINARY,
-        .plugin.store = ly_type_store_binary,
+        .plugin.store = lyplg_type_store_binary,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple,
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple,
     },
     {0}
 };
diff --git a/src/plugins_types_bits.c b/src/plugins_types_bits.c
index ac36a9a..ca08d64 100644
--- a/src/plugins_types_bits.c
+++ b/src/plugins_types_bits.c
@@ -31,7 +31,7 @@
 #include "plugins_internal.h" /* LY_TYPE_*_STR */
 
 API LY_ERR
-ly_type_store_bits(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+lyplg_type_store_bits(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_FORMAT UNUSED(format), void *UNUSED(prefix_data), uint32_t hints,
         const struct lysc_node *UNUSED(ctx_node), struct lyd_value *storage, struct lys_glob_unres *UNUSED(unres),
         struct ly_err_item **err)
@@ -57,7 +57,7 @@
     *err = NULL;
 
     /* check hints */
-    ret = ly_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
+    ret = lyplg_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
     LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup_value);
 
     /* remember the present items for further work */
@@ -169,7 +169,7 @@
 
     /* RETURN LY_SUCCESS */
     ly_set_free(items, NULL);
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         free((char *)value);
     }
     return LY_SUCCESS;
@@ -180,7 +180,7 @@
     free(buf);
     ly_set_free(items, NULL);
 cleanup_value:
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         free((char *)value);
     }
 
@@ -188,7 +188,7 @@
 }
 
 API LY_ERR
-ly_type_dup_bits(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
+lyplg_type_dup_bits(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
 {
     LY_ERR ret = LY_SUCCESS;
     LY_ARRAY_COUNT_TYPE u;
@@ -213,7 +213,7 @@
 }
 
 API void
-ly_type_free_bits(const struct ly_ctx *ctx, struct lyd_value *value)
+lyplg_type_free_bits(const struct ly_ctx *ctx, struct lyd_value *value)
 {
     LY_ARRAY_FREE(value->bits_items);
     value->bits_items = NULL;
@@ -237,12 +237,12 @@
 
         .plugin.id = "libyang 2 - bits, version 1",
         .plugin.type = LY_TYPE_BITS,
-        .plugin.store = ly_type_store_bits,
+        .plugin.store = lyplg_type_store_bits,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_bits,
-        .plugin.free = ly_type_free_bits
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_bits,
+        .plugin.free = lyplg_type_free_bits
     },
     {0}
 };
diff --git a/src/plugins_types_boolean.c b/src/plugins_types_boolean.c
index faabc2b..05e33af 100644
--- a/src/plugins_types_boolean.c
+++ b/src/plugins_types_boolean.c
@@ -29,7 +29,7 @@
 #include "plugins_internal.h" /* LY_TYPE_*_STR */
 
 API LY_ERR
-ly_type_store_boolean(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+lyplg_type_store_boolean(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_FORMAT UNUSED(format), void *UNUSED(prefix_data), uint32_t hints,
         const struct lysc_node *UNUSED(ctx_node), struct lyd_value *storage, struct lys_glob_unres *UNUSED(unres),
         struct ly_err_item **err)
@@ -40,7 +40,7 @@
     *err = NULL;
 
     /* check hints */
-    ret = ly_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
+    ret = lyplg_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
     LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
 
     if ((value_len == ly_strlen_const("true")) && !strncmp(value, "true", ly_strlen_const("true"))) {
@@ -52,9 +52,9 @@
         goto cleanup;
     }
 
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         ret = lydict_insert_zc(ctx, (char *)value, &storage->canonical);
-        options &= ~LY_TYPE_STORE_DYNAMIC;
+        options &= ~LYPLG_TYPE_STORE_DYNAMIC;
         LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
     } else {
         ret = lydict_insert(ctx, value, value_len, &storage->canonical);
@@ -64,7 +64,7 @@
     storage->realtype = type;
 
 cleanup:
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         free((char *)value);
     }
     return ret;
@@ -85,12 +85,12 @@
 
         .plugin.id = "libyang 2 - boolean, version 1",
         .plugin.type = LY_TYPE_BOOL,
-        .plugin.store = ly_type_store_boolean,
+        .plugin.store = lyplg_type_store_boolean,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     },
     {0}
 };
diff --git a/src/plugins_types_decimal64.c b/src/plugins_types_decimal64.c
index 8e0190a..56b9181 100644
--- a/src/plugins_types_decimal64.c
+++ b/src/plugins_types_decimal64.c
@@ -30,7 +30,7 @@
 #include "plugins_internal.h" /* LY_TYPE_*_STR */
 
 API LY_ERR
-ly_type_store_decimal64(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+lyplg_type_store_decimal64(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_FORMAT UNUSED(format), void *UNUSED(prefix_data), uint32_t hints,
         const struct lysc_node *UNUSED(ctx_node), struct lyd_value *storage, struct lys_glob_unres *UNUSED(unres),
         struct ly_err_item **err)
@@ -48,10 +48,10 @@
     }
 
     /* check hints */
-    ret = ly_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
+    ret = lyplg_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
     LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
 
-    ret = ly_type_parse_dec64(type_dec->fraction_digits, value, value_len, &d, err);
+    ret = lyplg_type_parse_dec64(type_dec->fraction_digits, value, value_len, &d, err);
     LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
     /* prepare canonized value */
     if (d) {
@@ -82,7 +82,7 @@
 
     /* range of the number */
     if (type_dec->range) {
-        ret = ly_type_validate_range(type->basetype, type_dec->range, d, buf, err);
+        ret = lyplg_type_validate_range(type->basetype, type_dec->range, d, buf, err);
         LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
     }
 
@@ -92,7 +92,7 @@
     storage->realtype = type;
 
 cleanup:
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         free((char *)value);
     }
     return ret;
@@ -113,12 +113,12 @@
 
         .plugin.id = "libyang 2 - decimal64, version 1",
         .plugin.type = LY_TYPE_DEC64,
-        .plugin.store = ly_type_store_decimal64,
+        .plugin.store = lyplg_type_store_decimal64,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     },
     {0}
 };
diff --git a/src/plugins_types_empty.c b/src/plugins_types_empty.c
index 4ace7ca..520ac4b 100644
--- a/src/plugins_types_empty.c
+++ b/src/plugins_types_empty.c
@@ -28,7 +28,7 @@
 #include "plugins_internal.h" /* LY_TYPE_*_STR */
 
 API LY_ERR
-ly_type_store_empty(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+lyplg_type_store_empty(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_FORMAT UNUSED(format), void *UNUSED(prefix_data), uint32_t hints,
         const struct lysc_node *UNUSED(ctx_node), struct lyd_value *storage, struct lys_glob_unres *UNUSED(unres),
         struct ly_err_item **err)
@@ -38,7 +38,7 @@
     *err = NULL;
 
     /* check hints */
-    ret = ly_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
+    ret = lyplg_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
     LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
 
     if (value_len) {
@@ -46,9 +46,9 @@
         goto cleanup;
     }
 
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         ret = lydict_insert_zc(ctx, (char *)value, &storage->canonical);
-        options &= ~LY_TYPE_STORE_DYNAMIC;
+        options &= ~LYPLG_TYPE_STORE_DYNAMIC;
         LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
     } else {
         ret = lydict_insert(ctx, "", value_len, &storage->canonical);
@@ -58,14 +58,14 @@
     storage->realtype = type;
 
 cleanup:
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         free((char *)value);
     }
     return ret;
 }
 
 API LY_ERR
-ly_type_compare_empty(const struct lyd_value *val1, const struct lyd_value *val2)
+lyplg_type_compare_empty(const struct lyd_value *val1, const struct lyd_value *val2)
 {
     if (val1->realtype != val2->realtype) {
         return LY_ENOT;
@@ -90,12 +90,12 @@
 
         .plugin.id = "libyang 2 - empty, version 1",
         .plugin.type = LY_TYPE_EMPTY,
-        .plugin.store = ly_type_store_empty,
+        .plugin.store = lyplg_type_store_empty,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_empty,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_empty,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     },
     {0}
 };
diff --git a/src/plugins_types_enumeration.c b/src/plugins_types_enumeration.c
index 2c8833b..879aee9 100644
--- a/src/plugins_types_enumeration.c
+++ b/src/plugins_types_enumeration.c
@@ -28,7 +28,7 @@
 #include "plugins_internal.h" /* LY_TYPE_*_STR */
 
 API LY_ERR
-ly_type_store_enum(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+lyplg_type_store_enum(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_FORMAT UNUSED(format), void *UNUSED(prefix_data), uint32_t hints,
         const struct lysc_node *UNUSED(ctx_node), struct lyd_value *storage, struct lys_glob_unres *UNUSED(unres),
         struct ly_err_item **err)
@@ -40,7 +40,7 @@
     *err = NULL;
 
     /* check hints */
-    ret = ly_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
+    ret = lyplg_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
     LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
 
     /* find the matching enumeration value item */
@@ -57,9 +57,9 @@
 match:
     /* validation done */
 
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         ret = lydict_insert_zc(ctx, (char *)value, &storage->canonical);
-        options &= ~LY_TYPE_STORE_DYNAMIC;
+        options &= ~LYPLG_TYPE_STORE_DYNAMIC;
         LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
     } else {
         ret = lydict_insert(ctx, value_len ? value : "", value_len, &storage->canonical);
@@ -69,7 +69,7 @@
     storage->realtype = type;
 
 cleanup:
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         free((char *) value);
     }
 
@@ -91,12 +91,12 @@
 
         .plugin.id = "libyang 2 - enumeration, version 1",
         .plugin.type = LY_TYPE_ENUM,
-        .plugin.store = ly_type_store_enum,
+        .plugin.store = lyplg_type_store_enum,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     },
     {0}
 };
diff --git a/src/plugins_types_identityref.c b/src/plugins_types_identityref.c
index a07c082..e337d41 100644
--- a/src/plugins_types_identityref.c
+++ b/src/plugins_types_identityref.c
@@ -30,12 +30,12 @@
 #include "plugins_internal.h" /* LY_TYPE_*_STR */
 
 API const char *
-ly_type_print_identityref(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data, ly_bool *dynamic)
+lyplg_type_print_identityref(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data, ly_bool *dynamic)
 {
     char *result = NULL;
 
     *dynamic = 1;
-    if (asprintf(&result, "%s:%s", ly_type_get_prefix(value->ident->module, format, prefix_data), value->ident->name) == -1) {
+    if (asprintf(&result, "%s:%s", lyplg_type_get_prefix(value->ident->module, format, prefix_data), value->ident->name) == -1) {
         return NULL;
     } else {
         return result;
@@ -43,7 +43,7 @@
 }
 
 API LY_ERR
-ly_type_store_identityref(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+lyplg_type_store_identityref(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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)
 {
@@ -60,7 +60,7 @@
     *err = NULL;
 
     /* check hints */
-    ret = ly_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
+    ret = lyplg_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
     LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
 
     /* locate prefix if any */
@@ -79,7 +79,7 @@
         goto cleanup;
     }
 
-    mod = ly_type_identity_module(ctx, ctx_node, prefix, prefix_len, format, prefix_data);
+    mod = lyplg_type_identity_module(ctx, ctx_node, prefix, prefix_len, format, prefix_data);
     if (!mod) {
         ret = ly_err_new(err, LY_EVALID, LYVE_DATA, NULL, NULL,
                 "Invalid identityref \"%.*s\" value - unable to map prefix to YANG schema.", (int)value_len, value);
@@ -102,8 +102,8 @@
         goto cleanup;
     } else if (!mod->implemented) {
         /* non-implemented module */
-        if (options & LY_TYPE_STORE_IMPLEMENT) {
-            ret = ly_type_make_implemented((struct lys_module *)mod, NULL, unres);
+        if (options & LYPLG_TYPE_STORE_IMPLEMENT) {
+            ret = lyplg_type_make_implemented((struct lys_module *)mod, NULL, unres);
             LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
         } else {
             ret = ly_err_new(err, LY_EVALID, LYVE_DATA, NULL, NULL,
@@ -115,7 +115,7 @@
 
     /* check that the identity matches some of the type's base identities */
     LY_ARRAY_FOR(type_ident->bases, u) {
-        if (!ly_type_identity_isderived(type_ident->bases[u], ident)) {
+        if (!lyplg_type_identity_isderived(type_ident->bases[u], ident)) {
             /* we have match */
             break;
         }
@@ -147,14 +147,14 @@
     storage->ident = ident;
 
     /* get JSON form since there is no canonical */
-    str = (char *)ly_type_print_identityref(storage, LY_PREF_JSON, NULL, &dyn);
+    str = (char *)lyplg_type_print_identityref(storage, LY_PREF_JSON, NULL, &dyn);
     assert(str && dyn);
     ret = lydict_insert_zc(ctx, str, &storage->canonical);
     LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
     storage->realtype = type;
 
 cleanup:
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         free((char *)value);
     }
 
@@ -162,7 +162,7 @@
 }
 
 API LY_ERR
-ly_type_compare_identityref(const struct lyd_value *val1, const struct lyd_value *val2)
+lyplg_type_compare_identityref(const struct lyd_value *val1, const struct lyd_value *val2)
 {
     if (val1->realtype != val2->realtype) {
         return LY_ENOT;
@@ -189,12 +189,12 @@
 
         .plugin.id = "libyang 2 - identityref, version 1",
         .plugin.type = LY_TYPE_IDENT,
-        .plugin.store = ly_type_store_identityref,
+        .plugin.store = lyplg_type_store_identityref,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_identityref,
-        .plugin.print = ly_type_print_identityref,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_identityref,
+        .plugin.print = lyplg_type_print_identityref,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     },
     {0}
 };
diff --git a/src/plugins_types_instanceid.c b/src/plugins_types_instanceid.c
index ccfd61f..f301097 100644
--- a/src/plugins_types_instanceid.c
+++ b/src/plugins_types_instanceid.c
@@ -32,7 +32,7 @@
 #include "plugins_internal.h" /* LY_TYPE_*_STR */
 
 API const char *
-ly_type_print_instanceid(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data, ly_bool *dynamic)
+lyplg_type_print_instanceid(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data, ly_bool *dynamic)
 {
     LY_ARRAY_COUNT_TYPE u, v;
     char *result = NULL;
@@ -45,7 +45,7 @@
     if ((format == LY_PREF_XML) || (format == LY_PREF_SCHEMA)) {
         /* everything is prefixed */
         LY_ARRAY_FOR(value->target, u) {
-            ly_strcat(&result, "/%s:%s", ly_type_get_prefix(value->target[u].node->module, format, prefix_data),
+            ly_strcat(&result, "/%s:%s", lyplg_type_get_prefix(value->target[u].node->module, format, prefix_data),
                     value->target[u].node->name);
             LY_ARRAY_FOR(value->target[u].predicates, v) {
                 struct ly_path_predicate *pred = &value->target[u].predicates[v];
@@ -65,7 +65,7 @@
                     if (strchr(str, quot)) {
                         quot = '"';
                     }
-                    ly_strcat(&result, "[%s:%s=%c%s%c]", ly_type_get_prefix(pred->key->module, format, prefix_data),
+                    ly_strcat(&result, "[%s:%s=%c%s%c]", lyplg_type_get_prefix(pred->key->module, format, prefix_data),
                             pred->key->name, quot, str, quot);
                     if (d) {
                         free((char *)str);
@@ -95,7 +95,7 @@
         LY_ARRAY_FOR(value->target, u) {
             if (mod != value->target[u].node->module) {
                 mod = value->target[u].node->module;
-                ly_strcat(&result, "/%s:%s", ly_type_get_prefix(mod, format, prefix_data), value->target[u].node->name);
+                ly_strcat(&result, "/%s:%s", lyplg_type_get_prefix(mod, format, prefix_data), value->target[u].node->name);
             } else {
                 ly_strcat(&result, "/%s", value->target[u].node->name);
             }
@@ -151,7 +151,7 @@
 }
 
 API LY_ERR
-ly_type_store_instanceid(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+lyplg_type_store_instanceid(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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)
 {
@@ -165,10 +165,10 @@
     *err = NULL;
 
     /* check hints */
-    ret = ly_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
+    ret = lyplg_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
     LY_CHECK_GOTO(ret != LY_SUCCESS,  cleanup_value);
 
-    LY_CHECK_GOTO(ret = ly_type_lypath_new(ctx, value, value_len, options, format, prefix_data, ctx_node,
+    LY_CHECK_GOTO(ret = lyplg_type_lypath_new(ctx, value, value_len, options, format, prefix_data, ctx_node,
             unres, &path, err), cleanup);
 
     /* store resolved schema path */
@@ -176,17 +176,17 @@
     path = NULL;
 
     /* store JSON string value */
-    str = (char *)ly_type_print_instanceid(storage, LY_PREF_JSON, NULL, &dyn);
+    str = (char *)lyplg_type_print_instanceid(storage, LY_PREF_JSON, NULL, &dyn);
     assert(str && dyn);
     LY_CHECK_GOTO(ret = lydict_insert_zc(ctx, str, &storage->canonical), cleanup);
     storage->realtype = type;
 
     /* cleanup */
 cleanup:
-    ly_type_lypath_free(ctx, path);
+    lyplg_type_lypath_free(ctx, path);
 
 cleanup_value:
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         free((char *)value);
     }
 
@@ -199,7 +199,7 @@
 }
 
 API LY_ERR
-ly_type_validate_instanceid(const struct ly_ctx *UNUSED(ctx), const struct lysc_type *UNUSED(type),
+lyplg_type_validate_instanceid(const struct ly_ctx *UNUSED(ctx), const struct lysc_type *UNUSED(type),
         const struct lyd_node *UNUSED(ctx_node), const struct lyd_node *tree, struct lyd_value *storage,
         struct ly_err_item **err)
 {
@@ -219,7 +219,7 @@
 }
 
 API LY_ERR
-ly_type_compare_instanceid(const struct lyd_value *val1, const struct lyd_value *val2)
+lyplg_type_compare_instanceid(const struct lyd_value *val1, const struct lyd_value *val2)
 {
     LY_ARRAY_COUNT_TYPE u, v;
 
@@ -275,7 +275,7 @@
 }
 
 API LY_ERR
-ly_type_dup_instanceid(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
+lyplg_type_dup_instanceid(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
 {
     LY_CHECK_RET(lydict_insert(ctx, original->canonical, strlen(original->canonical), &dup->canonical));
     dup->realtype = original->realtype;
@@ -283,11 +283,11 @@
 }
 
 API void
-ly_type_free_instanceid(const struct ly_ctx *ctx, struct lyd_value *value)
+lyplg_type_free_instanceid(const struct ly_ctx *ctx, struct lyd_value *value)
 {
     ly_path_free(ctx, value->target);
     value->target = NULL;
-    ly_type_free_simple(ctx, value);
+    lyplg_type_free_simple(ctx, value);
 }
 
 /**
@@ -305,12 +305,12 @@
 
         .plugin.id = "libyang 2 - instance-identifier, version 1",
         .plugin.type = LY_TYPE_INST,
-        .plugin.store = ly_type_store_instanceid,
-        .plugin.validate = ly_type_validate_instanceid,
-        .plugin.compare = ly_type_compare_instanceid,
-        .plugin.print = ly_type_print_instanceid,
-        .plugin.duplicate = ly_type_dup_instanceid,
-        .plugin.free = ly_type_free_instanceid
+        .plugin.store = lyplg_type_store_instanceid,
+        .plugin.validate = lyplg_type_validate_instanceid,
+        .plugin.compare = lyplg_type_compare_instanceid,
+        .plugin.print = lyplg_type_print_instanceid,
+        .plugin.duplicate = lyplg_type_dup_instanceid,
+        .plugin.free = lyplg_type_free_instanceid
     },
     {0}
 };
diff --git a/src/plugins_types_integer.c b/src/plugins_types_integer.c
index dec3c4d..c1fdad8 100644
--- a/src/plugins_types_integer.c
+++ b/src/plugins_types_integer.c
@@ -29,7 +29,7 @@
 #include "plugins_internal.h" /* LY_TYPE_*_STR */
 
 API LY_ERR
-ly_type_store_int(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+lyplg_type_store_int(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_FORMAT UNUSED(format), void *UNUSED(prefix_data), uint32_t hints,
         const struct lysc_node *UNUSED(ctx_node), struct lyd_value *storage, struct lys_glob_unres *UNUSED(unres),
         struct ly_err_item **err)
@@ -41,21 +41,21 @@
     struct lysc_type_num *type_num = (struct lysc_type_num *)type;
 
     /* check hints */
-    ret = ly_type_check_hints(hints, value, value_len, type->basetype, &base, err);
+    ret = lyplg_type_check_hints(hints, value, value_len, type->basetype, &base, err);
     LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
 
     switch (type->basetype) {
     case LY_TYPE_INT8:
-        ret = ly_type_parse_int("int8", base, INT64_C(-128), INT64_C(127), value, value_len, &num, err);
+        ret = lyplg_type_parse_int("int8", base, INT64_C(-128), INT64_C(127), value, value_len, &num, err);
         break;
     case LY_TYPE_INT16:
-        ret = ly_type_parse_int("int16", base, INT64_C(-32768), INT64_C(32767), value, value_len, &num, err);
+        ret = lyplg_type_parse_int("int16", base, INT64_C(-32768), INT64_C(32767), value, value_len, &num, err);
         break;
     case LY_TYPE_INT32:
-        ret = ly_type_parse_int("int32", base, INT64_C(-2147483648), INT64_C(2147483647), value, value_len, &num, err);
+        ret = lyplg_type_parse_int("int32", base, INT64_C(-2147483648), INT64_C(2147483647), value, value_len, &num, err);
         break;
     case LY_TYPE_INT64:
-        ret = ly_type_parse_int("int64", base, INT64_C(-9223372036854775807) - INT64_C(1),
+        ret = lyplg_type_parse_int("int64", base, INT64_C(-9223372036854775807) - INT64_C(1),
                 INT64_C(9223372036854775807), value, value_len, &num, err);
         break;
     default:
@@ -68,7 +68,7 @@
 
     /* range of the number */
     if (type_num->range) {
-        ret = ly_type_validate_range(type->basetype, type_num->range, num, str, err);
+        ret = lyplg_type_validate_range(type->basetype, type_num->range, num, str, err);
         LY_CHECK_ERR_GOTO(ret != LY_SUCCESS, free(str), cleanup);
     }
 
@@ -79,14 +79,14 @@
     storage->realtype = type;
 
 cleanup:
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         free((char *)value);
     }
     return ret;
 }
 
 API LY_ERR
-ly_type_store_uint(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+lyplg_type_store_uint(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_FORMAT UNUSED(format), void *UNUSED(prefix_data), uint32_t hints,
         const struct lysc_node *UNUSED(ctx_node), struct lyd_value *storage, struct lys_glob_unres *UNUSED(unres),
         struct ly_err_item **err)
@@ -98,21 +98,21 @@
     char *str;
 
     /* check hints */
-    ret = ly_type_check_hints(hints, value, value_len, type->basetype, &base, err);
+    ret = lyplg_type_check_hints(hints, value, value_len, type->basetype, &base, err);
     LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
 
     switch (type->basetype) {
     case LY_TYPE_UINT8:
-        ret = ly_type_parse_uint("uint8", base, UINT64_C(255), value, value_len, &num, err);
+        ret = lyplg_type_parse_uint("uint8", base, UINT64_C(255), value, value_len, &num, err);
         break;
     case LY_TYPE_UINT16:
-        ret = ly_type_parse_uint("uint16", base, UINT64_C(65535), value, value_len, &num, err);
+        ret = lyplg_type_parse_uint("uint16", base, UINT64_C(65535), value, value_len, &num, err);
         break;
     case LY_TYPE_UINT32:
-        ret = ly_type_parse_uint("uint32", base, UINT64_C(4294967295), value, value_len, &num, err);
+        ret = lyplg_type_parse_uint("uint32", base, UINT64_C(4294967295), value, value_len, &num, err);
         break;
     case LY_TYPE_UINT64:
-        ret = ly_type_parse_uint("uint64", base, UINT64_C(18446744073709551615), value, value_len, &num, err);
+        ret = lyplg_type_parse_uint("uint64", base, UINT64_C(18446744073709551615), value, value_len, &num, err);
         break;
     default:
         LOGINT(ctx);
@@ -124,7 +124,7 @@
 
     /* range of the number */
     if (type_num->range) {
-        ret = ly_type_validate_range(type->basetype, type_num->range, num, str, err);
+        ret = lyplg_type_validate_range(type->basetype, type_num->range, num, str, err);
         LY_CHECK_ERR_GOTO(ret != LY_SUCCESS, free(str), cleanup);
     }
 
@@ -135,7 +135,7 @@
     storage->realtype = type;
 
 cleanup:
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         free((char *)value);
     }
     return ret;
@@ -156,12 +156,12 @@
 
         .plugin.id = "libyang 2 - integers, version 1",
         .plugin.type = LY_TYPE_UINT8,
-        .plugin.store = ly_type_store_uint,
+        .plugin.store = lyplg_type_store_uint,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     }, {
         .module = "",
         .revision = NULL,
@@ -169,12 +169,12 @@
 
         .plugin.id = "libyang 2 - integers, version 1",
         .plugin.type = LY_TYPE_UINT16,
-        .plugin.store = ly_type_store_uint,
+        .plugin.store = lyplg_type_store_uint,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     }, {
         .module = "",
         .revision = NULL,
@@ -182,12 +182,12 @@
 
         .plugin.id = "libyang 2 - integers, version 1",
         .plugin.type = LY_TYPE_UINT32,
-        .plugin.store = ly_type_store_uint,
+        .plugin.store = lyplg_type_store_uint,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     }, {
         .module = "",
         .revision = NULL,
@@ -195,12 +195,12 @@
 
         .plugin.id = "libyang 2 - integers, version 1",
         .plugin.type = LY_TYPE_UINT64,
-        .plugin.store = ly_type_store_uint,
+        .plugin.store = lyplg_type_store_uint,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     }, {
         .module = "",
         .revision = NULL,
@@ -208,12 +208,12 @@
 
         .plugin.id = "libyang 2 - integers, version 1",
         .plugin.type = LY_TYPE_INT8,
-        .plugin.store = ly_type_store_int,
+        .plugin.store = lyplg_type_store_int,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     }, {
         .module = "",
         .revision = NULL,
@@ -221,12 +221,12 @@
 
         .plugin.id = "libyang 2 - integers, version 1",
         .plugin.type = LY_TYPE_INT16,
-        .plugin.store = ly_type_store_int,
+        .plugin.store = lyplg_type_store_int,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     }, {
         .module = "",
         .revision = NULL,
@@ -234,12 +234,12 @@
 
         .plugin.id = "libyang 2 - integers, version 1",
         .plugin.type = LY_TYPE_INT32,
-        .plugin.store = ly_type_store_int,
+        .plugin.store = lyplg_type_store_int,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     }, {
         .module = "",
         .revision = NULL,
@@ -247,12 +247,12 @@
 
         .plugin.id = "libyang 2 - integers, version 1",
         .plugin.type = LY_TYPE_INT64,
-        .plugin.store = ly_type_store_int,
+        .plugin.store = lyplg_type_store_int,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     },
     {0}
 };
diff --git a/src/plugins_types_leafref.c b/src/plugins_types_leafref.c
index 34b775b..38209d4 100644
--- a/src/plugins_types_leafref.c
+++ b/src/plugins_types_leafref.c
@@ -31,7 +31,7 @@
 const struct lyplg_type_record plugins_leafref[];
 
 API LY_ERR
-ly_type_store_leafref(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+lyplg_type_store_leafref(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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)
 {
@@ -58,7 +58,7 @@
 }
 
 API LY_ERR
-ly_type_validate_leafref(const struct ly_ctx *UNUSED(ctx), const struct lysc_type *type, const struct lyd_node *ctx_node,
+lyplg_type_validate_leafref(const struct ly_ctx *UNUSED(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)
 {
     LY_ERR ret = LY_SUCCESS;
@@ -73,7 +73,7 @@
     }
 
     /* check leafref target existence */
-    if (ly_type_resolve_leafref(type_lr, ctx_node, storage, tree, NULL, &errmsg)) {
+    if (lyplg_type_resolve_leafref(type_lr, ctx_node, storage, tree, NULL, &errmsg)) {
         ret = ly_err_new(err, LY_EVALID, LYVE_DATA, NULL, NULL, errmsg);
         if (errmsg != NULL) {
             free(errmsg);
@@ -84,25 +84,25 @@
 }
 
 API LY_ERR
-ly_type_compare_leafref(const struct lyd_value *val1, const struct lyd_value *val2)
+lyplg_type_compare_leafref(const struct lyd_value *val1, const struct lyd_value *val2)
 {
     return val1->realtype->plugin->compare(val1, val2);
 }
 
 API const char *
-ly_type_print_leafref(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data, ly_bool *dynamic)
+lyplg_type_print_leafref(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data, ly_bool *dynamic)
 {
     return value->realtype->plugin->print(value, format, prefix_data, dynamic);
 }
 
 API LY_ERR
-ly_type_dup_leafref(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
+lyplg_type_dup_leafref(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
 {
     return original->realtype->plugin->duplicate(ctx, original, dup);
 }
 
 API void
-ly_type_free_leafref(const struct ly_ctx *ctx, struct lyd_value *value)
+lyplg_type_free_leafref(const struct ly_ctx *ctx, struct lyd_value *value)
 {
     if (value->realtype->plugin != &plugins_leafref[0].plugin) {
         /* leafref's realtype is again leafref only in case of incomplete store */
@@ -125,12 +125,12 @@
 
         .plugin.id = "libyang 2 - leafref, version 1",
         .plugin.type = LY_TYPE_LEAFREF,
-        .plugin.store = ly_type_store_leafref,
-        .plugin.validate = ly_type_validate_leafref,
-        .plugin.compare = ly_type_compare_leafref,
-        .plugin.print = ly_type_print_leafref,
-        .plugin.duplicate = ly_type_dup_leafref,
-        .plugin.free = ly_type_free_leafref
+        .plugin.store = lyplg_type_store_leafref,
+        .plugin.validate = lyplg_type_validate_leafref,
+        .plugin.compare = lyplg_type_compare_leafref,
+        .plugin.print = lyplg_type_print_leafref,
+        .plugin.duplicate = lyplg_type_dup_leafref,
+        .plugin.free = lyplg_type_free_leafref
     },
     {0}
 };
diff --git a/src/plugins_types_string.c b/src/plugins_types_string.c
index 2e170d7..bbd420c 100644
--- a/src/plugins_types_string.c
+++ b/src/plugins_types_string.c
@@ -28,7 +28,7 @@
 #include "plugins_internal.h" /* LY_TYPE_*_STR */
 
 API LY_ERR
-ly_type_store_string(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+lyplg_type_store_string(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_FORMAT UNUSED(format), void *UNUSED(prefix_data), uint32_t hints,
         const struct lysc_node *UNUSED(ctx_node), struct lyd_value *storage, struct lys_glob_unres *UNUSED(unres),
         struct ly_err_item **err)
@@ -37,7 +37,7 @@
     struct lysc_type_str *type_str = (struct lysc_type_str *)type;
 
     /* check hints */
-    ret = ly_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
+    ret = lyplg_type_check_hints(hints, value, value_len, type->basetype, NULL, err);
     LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
 
     /* length restriction of the string */
@@ -47,17 +47,17 @@
 
         /* value_len is in bytes, but we need number of chaarcters here */
         snprintf(buf, LY_NUMBER_MAXLEN, "%zu", char_count);
-        ret = ly_type_validate_range(LY_TYPE_BINARY, type_str->length, char_count, buf, err);
+        ret = lyplg_type_validate_range(LY_TYPE_BINARY, type_str->length, char_count, buf, err);
         LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
     }
 
     /* pattern restrictions */
-    ret = ly_type_validate_patterns(type_str->patterns, value, value_len, err);
+    ret = lyplg_type_validate_patterns(type_str->patterns, value, value_len, err);
     LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
 
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         ret = lydict_insert_zc(ctx, (char *)value, &storage->canonical);
-        options &= ~LY_TYPE_STORE_DYNAMIC;
+        options &= ~LYPLG_TYPE_STORE_DYNAMIC;
         LY_CHECK_GOTO(ret != LY_SUCCESS, cleanup);
     } else {
         ret = lydict_insert(ctx, value_len ? value : "", value_len, &storage->canonical);
@@ -67,7 +67,7 @@
     storage->realtype = type;
 
 cleanup:
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         free((char *)value);
     }
 
@@ -89,12 +89,12 @@
 
         .plugin.id = "libyang 2 - string, version 1",
         .plugin.type = LY_TYPE_STRING,
-        .plugin.store = ly_type_store_string,
+        .plugin.store = lyplg_type_store_string,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     },
     {0}
 };
diff --git a/src/plugins_types_union.c b/src/plugins_types_union.c
index c3337cf..1c57a65 100644
--- a/src/plugins_types_union.c
+++ b/src/plugins_types_union.c
@@ -81,7 +81,7 @@
 }
 
 API LY_ERR
-ly_type_store_union(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
+lyplg_type_store_union(const struct ly_ctx *ctx, const struct lysc_type *type, const char *value, size_t value_len,
         uint32_t options, LY_PREFIX_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)
 {
@@ -99,9 +99,9 @@
     }
 
     /* remember the original value */
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         ret = lydict_insert_zc(ctx, (char *)value, &subvalue->original);
-        options &= ~LY_TYPE_STORE_DYNAMIC;
+        options &= ~LYPLG_TYPE_STORE_DYNAMIC;
         LY_CHECK_GOTO(ret, cleanup);
     } else {
         ret = lydict_insert(ctx, value_len ? value : "", value_len, &subvalue->original);
@@ -109,7 +109,7 @@
     }
 
     /* store format-specific data for later prefix resolution */
-    ret = ly_type_prefix_data_new(ctx, subvalue->original, value_len, format, prefix_data, &subvalue->format,
+    ret = lyplg_type_prefix_data_new(ctx, subvalue->original, value_len, format, prefix_data, &subvalue->format,
             &subvalue->prefix_data);
     LY_CHECK_GOTO(ret, cleanup);
     subvalue->hints = hints;
@@ -122,7 +122,7 @@
 cleanup:
     if ((ret != LY_SUCCESS) && (ret != LY_EINCOMPLETE)) {
         lydict_remove(ctx, subvalue->original);
-        ly_type_prefix_data_free(subvalue->format, subvalue->prefix_data);
+        lyplg_type_prefix_data_free(subvalue->format, subvalue->prefix_data);
         free(subvalue);
     } else {
         /* store it as union, the specific type is in the subvalue, but canonical value is the specific type value */
@@ -133,7 +133,7 @@
     }
 
 cleanup_value:
-    if (options & LY_TYPE_STORE_DYNAMIC) {
+    if (options & LYPLG_TYPE_STORE_DYNAMIC) {
         free((char *)value);
     }
 
@@ -141,7 +141,7 @@
 }
 
 API LY_ERR
-ly_type_validate_union(const struct ly_ctx *ctx, const struct lysc_type *type, const struct lyd_node *ctx_node,
+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)
 {
     LY_ERR ret = LY_SUCCESS;
@@ -179,7 +179,7 @@
 }
 
 API LY_ERR
-ly_type_compare_union(const struct lyd_value *val1, const struct lyd_value *val2)
+lyplg_type_compare_union(const struct lyd_value *val1, const struct lyd_value *val2)
 {
     if (val1->realtype != val2->realtype) {
         return LY_ENOT;
@@ -192,13 +192,13 @@
 }
 
 API const char *
-ly_type_print_union(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data, ly_bool *dynamic)
+lyplg_type_print_union(const struct lyd_value *value, LY_PREFIX_FORMAT format, void *prefix_data, ly_bool *dynamic)
 {
     return value->subvalue->value.realtype->plugin->print(&value->subvalue->value, format, prefix_data, dynamic);
 }
 
 API LY_ERR
-ly_type_dup_union(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
+lyplg_type_dup_union(const struct ly_ctx *ctx, const struct lyd_value *original, struct lyd_value *dup)
 {
     LY_CHECK_RET(lydict_insert(ctx, original->canonical, strlen(original->canonical), &dup->canonical));
 
@@ -209,7 +209,7 @@
     LY_CHECK_RET(lydict_insert(ctx, original->subvalue->original, strlen(original->subvalue->original),
             &dup->subvalue->original));
     dup->subvalue->format = original->subvalue->format;
-    LY_CHECK_RET(ly_type_prefix_data_dup(ctx, original->subvalue->format, original->subvalue->prefix_data,
+    LY_CHECK_RET(lyplg_type_prefix_data_dup(ctx, original->subvalue->format, original->subvalue->prefix_data,
             &dup->subvalue->prefix_data));
 
     dup->realtype = original->realtype;
@@ -217,14 +217,14 @@
 }
 
 API void
-ly_type_free_union(const struct ly_ctx *ctx, struct lyd_value *value)
+lyplg_type_free_union(const struct ly_ctx *ctx, struct lyd_value *value)
 {
     lydict_remove(ctx, value->canonical);
     if (value->subvalue) {
         if (value->subvalue->value.realtype) {
             value->subvalue->value.realtype->plugin->free(ctx, &value->subvalue->value);
         }
-        ly_type_prefix_data_free(value->subvalue->format, value->subvalue->prefix_data);
+        lyplg_type_prefix_data_free(value->subvalue->format, value->subvalue->prefix_data);
         lydict_remove(ctx, value->subvalue->original);
         free(value->subvalue);
         value->subvalue = NULL;
@@ -246,12 +246,12 @@
 
         .plugin.id = "libyang 2 - union,version 1",
         .plugin.type = LY_TYPE_UNION,
-        .plugin.store = ly_type_store_union,
-        .plugin.validate = ly_type_validate_union,
-        .plugin.compare = ly_type_compare_union,
-        .plugin.print = ly_type_print_union,
-        .plugin.duplicate = ly_type_dup_union,
-        .plugin.free = ly_type_free_union
+        .plugin.store = lyplg_type_store_union,
+        .plugin.validate = lyplg_type_validate_union,
+        .plugin.compare = lyplg_type_compare_union,
+        .plugin.print = lyplg_type_print_union,
+        .plugin.duplicate = lyplg_type_dup_union,
+        .plugin.free = lyplg_type_free_union
     },
     {0}
 };
diff --git a/src/schema_compile.c b/src/schema_compile.c
index d725efb..19e8a3a 100644
--- a/src/schema_compile.c
+++ b/src/schema_compile.c
@@ -1093,7 +1093,7 @@
     uint32_t options;
     struct ly_err_item *err = NULL;
 
-    options = (ctx->ctx->flags & LY_CTX_REF_IMPLEMENTED) ? LY_TYPE_STORE_IMPLEMENT : 0;
+    options = (ctx->ctx->flags & LY_CTX_REF_IMPLEMENTED) ? LYPLG_TYPE_STORE_IMPLEMENT : 0;
     ret = type->plugin->store(ctx->ctx, type, dflt, strlen(dflt), options, LY_PREF_SCHEMA, (void *)dflt_pmod,
             LYD_HINT_SCHEMA, node, storage, unres, &err);
     if (ret == LY_EINCOMPLETE) {
diff --git a/src/schema_compile_node.c b/src/schema_compile_node.c
index b2cc259..65e0d2b 100644
--- a/src/schema_compile_node.c
+++ b/src/schema_compile_node.c
@@ -241,7 +241,7 @@
     LY_CHECK_ERR_RET(!(*when), LOGMEM(ctx->ctx), LY_EMEM);
     (*when)->refcount = 1;
     LY_CHECK_RET(lyxp_expr_parse(ctx->ctx, when_p->cond, 0, 1, &(*when)->cond));
-    LY_CHECK_RET(ly_type_prefix_data_new(ctx->ctx, when_p->cond, strlen(when_p->cond),
+    LY_CHECK_RET(lyplg_type_prefix_data_new(ctx->ctx, when_p->cond, strlen(when_p->cond),
             LY_PREF_SCHEMA, ctx->pmod, &format, (void **)&(*when)->prefixes));
     (*when)->context = (struct lysc_node *)ctx_node;
     DUP_STRING_GOTO(ctx->ctx, when_p->dsc, (*when)->dsc, ret, done);
@@ -303,7 +303,7 @@
     LY_PREFIX_FORMAT format;
 
     LY_CHECK_RET(lyxp_expr_parse(ctx->ctx, must_p->arg.str, 0, 1, &must->cond));
-    LY_CHECK_RET(ly_type_prefix_data_new(ctx->ctx, must_p->arg.str, strlen(must_p->arg.str),
+    LY_CHECK_RET(lyplg_type_prefix_data_new(ctx->ctx, must_p->arg.str, strlen(must_p->arg.str),
             LY_PREF_SCHEMA, must_p->arg.mod, &format, (void **)&must->prefixes));
     DUP_STRING_GOTO(ctx->ctx, must_p->eapptag, must->eapptag, ret, done);
     DUP_STRING_GOTO(ctx->ctx, must_p->emsg, must->emsg, ret, done);
@@ -1366,7 +1366,7 @@
                     lref->refcount = 1;
                     lref->cur_mod = ((struct lysc_type_leafref *)un_aux->types[v])->cur_mod;
                     lref->require_instance = ((struct lysc_type_leafref *)un_aux->types[v])->require_instance;
-                    ret = ly_type_prefix_data_dup(ctx->ctx, LY_PREF_SCHEMA_RESOLVED,
+                    ret = lyplg_type_prefix_data_dup(ctx->ctx, LY_PREF_SCHEMA_RESOLVED,
                             ((struct lysc_type_leafref *)un_aux->types[v])->prefixes, (void **)&lref->prefixes);
                     LY_CHECK_GOTO(ret, error);
                     /* TODO extensions */
@@ -1616,11 +1616,11 @@
             LY_PREFIX_FORMAT format;
 
             LY_CHECK_RET(lyxp_expr_dup(ctx->ctx, type_p->path, &lref->path));
-            LY_CHECK_RET(ly_type_prefix_data_new(ctx->ctx, type_p->path->expr, strlen(type_p->path->expr),
+            LY_CHECK_RET(lyplg_type_prefix_data_new(ctx->ctx, type_p->path->expr, strlen(type_p->path->expr),
                     LY_PREF_SCHEMA, type_p->pmod, &format, (void **)&lref->prefixes));
         } else if (base) {
             LY_CHECK_RET(lyxp_expr_dup(ctx->ctx, ((struct lysc_type_leafref *)base)->path, &lref->path));
-            LY_CHECK_RET(ly_type_prefix_data_dup(ctx->ctx, LY_PREF_SCHEMA_RESOLVED,
+            LY_CHECK_RET(lyplg_type_prefix_data_dup(ctx->ctx, LY_PREF_SCHEMA_RESOLVED,
                     ((struct lysc_type_leafref *)base)->prefixes, (void **)&lref->prefixes));
         } else if (tpdfname) {
             LOGVAL(ctx->ctx, LY_VCODE_MISSCHILDSTMT, "path", "leafref type ", tpdfname);
diff --git a/src/tree_data.c b/src/tree_data.c
index 3d4fe56..aca0a5d 100644
--- a/src/tree_data.c
+++ b/src/tree_data.c
@@ -61,7 +61,7 @@
 {
     LY_ERR ret;
     struct ly_err_item *err = NULL;
-    uint32_t options = (dynamic && *dynamic ? LY_TYPE_STORE_DYNAMIC : 0);
+    uint32_t options = (dynamic && *dynamic ? LYPLG_TYPE_STORE_DYNAMIC : 0);
 
     if (incomplete) {
         *incomplete = 0;
diff --git a/src/tree_data.h b/src/tree_data.h
index 24d03f8..9728359 100644
--- a/src/tree_data.h
+++ b/src/tree_data.h
@@ -478,7 +478,7 @@
     LY_PREFIX_FORMAT format;     /**< Prefix format of the value. However, this information is also used to decide
                                       whether a value is valid for the specific format or not on later validations
                                       (instance-identifier in XML looks different than in JSON). */
-    void *prefix_data;           /**< Format-specific data for prefix resolution (see ::ly_type_store_resolve_prefix()) */
+    void *prefix_data;           /**< Format-specific data for prefix resolution (see ly_resolve_prefix()) */
     uint32_t hints;              /**< [Value hints](@ref lydvalhints) from the parser */
     const struct lysc_node *ctx_node;   /**< Context schema node. */
 };
diff --git a/src/tree_schema.h b/src/tree_schema.h
index 2670781..c6f6bcd 100644
--- a/src/tree_schema.h
+++ b/src/tree_schema.h
@@ -507,7 +507,7 @@
     const char *stmt;                /**< identifier of the statement */
     const char *arg;                 /**< statement's argument */
     LY_PREFIX_FORMAT format;         /**< prefix format of the identifier/argument (::LY_PREF_XML is YIN format) */
-    void *prefix_data;               /**< Format-specific data for prefix resolution (see ::ly_type_store_resolve_prefix()) */
+    void *prefix_data;               /**< Format-specific data for prefix resolution (see ly_resolve_prefix()) */
 
     struct lysp_stmt *next;          /**< link to the next statement */
     struct lysp_stmt *child;         /**< list of the statement's substatements (linked list) */
@@ -525,7 +525,7 @@
     const char *argument;                   /**< optional value of the extension's argument */
     LY_PREFIX_FORMAT format;                /**< prefix format of the extension name/argument (::LY_PREF_XML is YIN format) */
     void *prefix_data;                      /**< Format-specific data for prefix resolution
-                                                 (see ::ly_type_store_resolve_prefix()) */
+                                                 (see ly_resolve_prefix()) */
 
     struct lysp_stmt *child;                /**< list of the extension's substatements (linked list) */
 
diff --git a/src/tree_schema_free.c b/src/tree_schema_free.c
index 2f4d7c5..f39c296 100644
--- a/src/tree_schema_free.c
+++ b/src/tree_schema_free.c
@@ -989,7 +989,7 @@
 }
 
 API void
-lysc_extension_instance_substatements_free(struct ly_ctx *ctx, struct lysc_ext_substmt *substmts)
+lyplg_ext_instance_substatements_free(struct ly_ctx *ctx, struct lysc_ext_substmt *substmts)
 {
     LY_ARRAY_COUNT_TYPE u;
 
diff --git a/src/xpath.c b/src/xpath.c
index bad1cc4..9deae1d 100644
--- a/src/xpath.c
+++ b/src/xpath.c
@@ -1570,7 +1570,7 @@
     }
 
     /* ignore errors, the value may not satisfy schema constraints */
-    rc = type->plugin->store(src->ctx, type, str, strlen(str), LY_TYPE_STORE_DYNAMIC, src->format, src->prefix_data,
+    rc = type->plugin->store(src->ctx, type, str, strlen(str), LYPLG_TYPE_STORE_DYNAMIC, src->format, src->prefix_data,
             LYD_HINT_DATA, xp_node->node->schema, &val, NULL, &err);
     ly_err_free(err);
     if (rc) {
@@ -3740,7 +3740,7 @@
         if (sleaf->nodetype & (LYS_LEAF | LYS_LEAFLIST)) {
             if (sleaf->type->basetype == LY_TYPE_LEAFREF) {
                 /* find leafref target */
-                if (ly_type_resolve_leafref((struct lysc_type_leafref *)sleaf->type, &leaf->node, &leaf->value, set->tree,
+                if (lyplg_type_resolve_leafref((struct lysc_type_leafref *)sleaf->type, &leaf->node, &leaf->value, set->tree,
                         &node, &errmsg)) {
                     LOGERR(set->ctx, LY_EVALID, errmsg);
                     free(errmsg);
@@ -4611,7 +4611,7 @@
         return rc;
     }
 
-    rc = ly_type_validate_patterns(patterns, args[0]->val.str, strlen(args[0]->val.str), &err);
+    rc = lyplg_type_validate_patterns(patterns, args[0]->val.str, strlen(args[0]->val.str), &err);
     pcre2_code_free((*pattern)->code);
     free(*pattern);
     LY_ARRAY_FREE(patterns);
diff --git a/tests/plugins/simple.c b/tests/plugins/simple.c
index 34f9e87..2b37ca2 100644
--- a/tests/plugins/simple.c
+++ b/tests/plugins/simple.c
@@ -27,14 +27,14 @@
 /**
  * @brief Compile NAMC's extension instances.
  *
- * Implementation of lyext_clb_compile callback set as lyext_plugin::compile.
+ * Implementation of ::lyplg_ext_compile_clb callback set as lyext_plugin::compile.
  */
 static LY_ERR
 hint_compile(struct lysc_ctx *cctx, const struct lysp_ext_instance *p_ext, struct lysc_ext_instance *c_ext)
 {
     /* check that the extension is instantiated at an allowed place - data node */
     if (!LY_STMT_IS_DATA_NODE(c_ext->parent_stmt)) {
-        lyext_log(c_ext, LY_LLWRN, 0, lysc_ctx_get_path(cctx),
+        lyplg_ext_log(c_ext, LY_LLWRN, 0, lysc_ctx_get_path(cctx),
                 "Extension %s is allowed only in a data nodes, but it is placed in \"%s\" statement.",
                 p_ext->name, ly_stmt2str(c_ext->parent_stmt));
         return LY_ENOT;
@@ -78,12 +78,12 @@
 
         .plugin.id = "libyang 2 - simple test, version 1",
         .plugin.type = LY_TYPE_UNKNOWN,
-        .plugin.store = ly_type_store_string,
+        .plugin.store = lyplg_type_store_string,
         .plugin.validate = NULL,
-        .plugin.compare = ly_type_compare_simple,
-        .plugin.print = ly_type_print_simple,
-        .plugin.duplicate = ly_type_dup_simple,
-        .plugin.free = ly_type_free_simple
+        .plugin.compare = lyplg_type_compare_simple,
+        .plugin.print = lyplg_type_print_simple,
+        .plugin.duplicate = lyplg_type_dup_simple,
+        .plugin.free = lyplg_type_free_simple
     },
     {0}
 };
diff --git a/tests/utests/types/bits.c b/tests/utests/types/bits.c
index 7b871e7..1e6b8f7 100644
--- a/tests/utests/types/bits.c
+++ b/tests/utests/types/bits.c
@@ -811,7 +811,7 @@
     alloc = (char *)malloc(strlen(val_text) + 1);
     memcpy(alloc, val_text, strlen(val_text) + 1);
     ly_ret = type->store(UTEST_LYCTX, lysc_type, alloc, strlen(val_text),
-            LY_TYPE_STORE_DYNAMIC, LY_PREF_XML, NULL, LYD_VALHINT_STRING, NULL, &value, NULL, &err);
+            LYPLG_TYPE_STORE_DYNAMIC, LY_PREF_XML, NULL, LYD_VALHINT_STRING, NULL, &value, NULL, &err);
     alloc = NULL;
     assert_int_equal(LY_SUCCESS, ly_ret);
     CHECK_LYD_VALUE(value, BITS, "two", "two");
diff --git a/tests/utests/types/int8.c b/tests/utests/types/int8.c
index a76a784..01f449e 100644
--- a/tests/utests/types/int8.c
+++ b/tests/utests/types/int8.c
@@ -1463,7 +1463,7 @@
 
     memcpy(alloc, val_text, strlen(val_text) + 1);
     ly_ret = type->store(UTEST_LYCTX, lysc_type, alloc, strlen(val_text),
-            LY_TYPE_STORE_DYNAMIC, LY_PREF_XML, NULL, LYD_VALHINT_HEXNUM, NULL, &value, NULL, &err);
+            LYPLG_TYPE_STORE_DYNAMIC, LY_PREF_XML, NULL, LYD_VALHINT_HEXNUM, NULL, &value, NULL, &err);
     alloc = NULL;
     assert_int_equal(LY_SUCCESS, ly_ret);
     CHECK_LYD_VALUE(value, INT8, "10", 10);
diff --git a/tests/utests/types/string.c b/tests/utests/types/string.c
index f771e39..9aee86b 100644
--- a/tests/utests/types/string.c
+++ b/tests/utests/types/string.c
@@ -1103,7 +1103,7 @@
     memcpy(alloc_text, val_text, alloc_text_size + 1);
 
     ly_ret = type->store(UTEST_LYCTX, lysc_type, alloc_text, alloc_text_size,
-            LY_TYPE_STORE_DYNAMIC, LY_PREF_XML, NULL, LYD_VALHINT_STRING, NULL, &value, NULL, &err);
+            LYPLG_TYPE_STORE_DYNAMIC, LY_PREF_XML, NULL, LYD_VALHINT_STRING, NULL, &value, NULL, &err);
     alloc_text = NULL;
     assert_int_equal(LY_SUCCESS, ly_ret);
     CHECK_LYD_VALUE(value, STRING, "<250>");