aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/libucl/ucl.h
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2017-01-10 12:35:55 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2017-01-10 12:35:55 +0000
commitcb846eabcdd306de3ff54c77ad0184f08850dead (patch)
treef4c4705c11f558631528857636d74807fc853223 /contrib/libucl/ucl.h
parent5e4f7ac4c8ec5cf319b3e0aa81cd8dfcf7d23f94 (diff)
downloadrspamd-cb846eabcdd306de3ff54c77ad0184f08850dead.tar.gz
rspamd-cb846eabcdd306de3ff54c77ad0184f08850dead.zip
[Feature] Add ucl_object_iterate_full function
Diffstat (limited to 'contrib/libucl/ucl.h')
-rw-r--r--contrib/libucl/ucl.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/contrib/libucl/ucl.h b/contrib/libucl/ucl.h
index 024f5dd8f..ec93bd7e1 100644
--- a/contrib/libucl/ucl.h
+++ b/contrib/libucl/ucl.h
@@ -831,10 +831,29 @@ UCL_EXTERN ucl_object_iter_t ucl_object_iterate_reset (ucl_object_iter_t it,
* Get the next object from the `obj`. This fucntion iterates over arrays, objects
* and implicit arrays
* @param iter safe iterator
+ * @param expand_values expand explicit arrays and objects
* @return the next object in sequence
*/
UCL_EXTERN const ucl_object_t* ucl_object_iterate_safe (ucl_object_iter_t iter,
bool expand_values);
+/**
+ * Iteration type enumerator
+ */
+enum ucl_iterate_type {
+ UCL_ITERATE_EXPLICIT = 1 << 0, /**< Iterate just explicit arrays and objects */
+ UCL_ITERATE_IMPLICIT = 1 << 1, /**< Iterate just implicit arrays */
+ UCL_ITERATE_BOTH = (1 << 0) | (1 << 1), /**< Iterate both explicit and implicit arrays*/
+};
+
+/**
+ * Get the next object from the `obj`. This fucntion iterates over arrays, objects
+ * and implicit arrays if needed
+ * @param iter safe iterator
+ * @param
+ * @return the next object in sequence
+ */
+UCL_EXTERN const ucl_object_t* ucl_object_iterate_full (ucl_object_iter_t iter,
+ enum ucl_iterate_type type);
/**
* Free memory associated with the safe iterator