7#include "../../_cexports/c_gev_server.h"
9#include "../../global.hpp"
11#include "../_decl/decl_node.hpp"
12#include "../_decl/decl_node_map.hpp"
13#include "../_decl/decl_server_base.hpp"
15#include "../../_decl/decl_device.hpp"
17#include "../category_node.hpp"
18#include "../value_node.hpp"
34 for (
const auto &entry : nodes_)
35 nodes[entry.first] = Node(entry.first);
39 inline void NodeMap::FillNodeKeys()
42 auto resultNum = CVB_CALL_CAPI(GSNodeCount(Handle(), numNodes));
48 size_t nameLength = 0;
49 auto resultNameLength = CVB_CALL_CAPI(GSNodeList(Handle(), i,
nullptr, nameLength));
50 if (resultNameLength < 0)
54 auto resultBuffer = CVB_CALL_CAPI(GSNodeList(Handle(), i, &buffer[0], nameLength));
57 String keyString(buffer.begin(), buffer.end() - 1);
62 inline void NodeMap::AddNode(
const String &key,
const NodePtr &value,
const NodeList &kind)
68 auto name = value->NameOnly();
73 return CExports::GSNAddNodeExTyped(value->Handle(),
static_cast<CExports::TGSNodeList
>(kind), key.data(),
83 inline std::size_t ChunkNodesSerializedSize(
const NodeMapPtr& nodemap)
89 CVB_CALL_CAPI_CHECKED(CVGSServerGetRequiredChunkSize(nodemap->Handle(), ret));
93 inline std::uint64_t SerializeChunkNodes(
const NodeMapPtr& nodemap,
void *buffer,
size_t size)
101 CVB_CALL_CAPI_CHECKED(CVGSServerWriteChunkMemory(nodemap->Handle(), buffer, size, layoutId));
Namespace for GevServer based device configuration.
Definition decl_int_swiss_knife_node.hpp:11
std::shared_ptr< ServerBase > ServerBasePtr
Convenience shared pointer for GevServer.
Definition gevserver.hpp:39
Root namespace for the Image Manager interface.
Definition version.hpp:11
std::string String
String for wide characters or unicode characters.
Definition string.hpp:49
T const_pointer_cast(T... args)
T rethrow_exception(T... args)