printer NEW function lyd_print_path()
diff --git a/src/tree_data.h b/src/tree_data.h
index 09af0dd..c6eec4d 100644
--- a/src/tree_data.h
+++ b/src/tree_data.h
@@ -1263,9 +1263,9 @@
/**
* @brief Print data tree in the specified format.
*
+ * @param[in] fd File descriptor where to print the data.
* @param[in] root Root node of the data tree to print. It can be actually any (not only real root)
* node of the data tree to print the specific subtree.
- * @param[in] fd File descriptor where to print the data.
* @param[in] format Data output format.
* @param[in] options [printer flags](@ref printerflags). \p format LYD_LYB accepts only #LYP_WITHSIBLINGS option.
* @return 0 on success, 1 on failure (#ly_errno is set).
@@ -1275,9 +1275,9 @@
/**
* @brief Print data tree in the specified format.
*
+ * @param[in] f File stream where to print the data.
* @param[in] root Root node of the data tree to print. It can be actually any (not only real root)
* node of the data tree to print the specific subtree.
- * @param[in] f File stream where to print the data.
* @param[in] format Data output format.
* @param[in] options [printer flags](@ref printerflags). \p format LYD_LYB accepts only #LYP_WITHSIBLINGS option.
* @return 0 on success, 1 on failure (#ly_errno is set).
@@ -1287,9 +1287,21 @@
/**
* @brief Print data tree in the specified format.
*
+ * @param[in] path File path where to print the data.
* @param[in] root Root node of the data tree to print. It can be actually any (not only real root)
* node of the data tree to print the specific subtree.
+ * @param[in] format Data output format.
+ * @param[in] options [printer flags](@ref printerflags). \p format LYD_LYB accepts only #LYP_WITHSIBLINGS option.
+ * @return 0 on success, 1 on failure (#ly_errno is set).
+ */
+int lyd_print_path(const char *path, const struct lyd_node *root, LYD_FORMAT format, int options);
+
+/**
+ * @brief Print data tree in the specified format.
+ *
* @param[in] writeclb Callback function to write the data (see write(1)).
+ * @param[in] root Root node of the data tree to print. It can be actually any (not only real root)
+ * node of the data tree to print the specific subtree.
* @param[in] arg Optional caller-specific argument to be passed to the \p writeclb callback.
* @param[in] format Data output format.
* @param[in] options [printer flags](@ref printerflags). \p format LYD_LYB accepts only #LYP_WITHSIBLINGS option.