libcamera: value_node: Support adding nested children in one operation
The GlobalConfiguration class will need to add nested children to a ValueNode. Add a new overload to the add() function for this purpose. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com>
This commit is contained in:
@@ -8,6 +8,7 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <initializer_list>
|
||||
#include <iterator>
|
||||
#include <map>
|
||||
#include <memory>
|
||||
@@ -239,6 +240,8 @@ public:
|
||||
|
||||
ValueNode *add(std::unique_ptr<ValueNode> &&child);
|
||||
ValueNode *add(std::string key, std::unique_ptr<ValueNode> &&child);
|
||||
ValueNode *add(std::initializer_list<std::string_view> path,
|
||||
std::unique_ptr<ValueNode> &&child);
|
||||
|
||||
private:
|
||||
LIBCAMERA_DISABLE_COPY_AND_MOVE(ValueNode)
|
||||
|
||||
Reference in New Issue
Block a user