diff options
author | Max Kellermann <max@musicpd.org> | 2018-06-03 20:05:37 +0200 |
---|---|---|
committer | Max Kellermann <max@musicpd.org> | 2018-06-03 20:05:37 +0200 |
commit | d4141bf7f1a3ad2ddb718e85d585dd8dc87ab5cd (patch) | |
tree | 52f6e34e742ded738bdea8103133d94190100276 /src/lib | |
parent | 6c81fa1ec5ef19839ce8df99e9d0310466a0164b (diff) |
lib/dbus/ReadIter: add API documentation
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/dbus/ReadIter.hxx | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/lib/dbus/ReadIter.hxx b/src/lib/dbus/ReadIter.hxx index 305f2de03..d51dd371c 100644 --- a/src/lib/dbus/ReadIter.hxx +++ b/src/lib/dbus/ReadIter.hxx @@ -74,10 +74,18 @@ public: return value; } + /** + * Create a new iterator which recurses into a container + * value. + */ ReadMessageIter Recurse() noexcept { return {RecurseTag(), *this}; } + /** + * Invoke a function for each element (including the current + * one), as long as the argument type is the specified one. + */ template<typename F> void ForEach(int arg_type, F &&f) { for (; GetArgType() == arg_type; Next()) |