synapse-app-sdk
C++ SDK for Synapse Apps
Loading...
Searching...
No Matches
config.hpp
1#pragma once
2
3#include <optional>
4#include <vector>
5
6#include "api/synapse.pb.h"
7
8namespace synapse {
9// Given a device configuration and node type, get all the node ids of that type
10// Empty if no nodes found
11std::vector<uint32_t> get_node_ids_for_type(const synapse::DeviceConfiguration& configuration,
12 const synapse::NodeType& type);
13
14// Given a device configuration and node type, return all the node configs for that type
15std::vector<synapse::NodeConfig> get_nodes_for_type(
16 const synapse::DeviceConfiguration& configuration, const synapse::NodeType& type);
17
18// Given a device configuration and node id, return the configuration for that node
19std::optional<synapse::NodeConfig> get_node_by_id(const synapse::DeviceConfiguration& configuration,
20 const uint32_t node_id);
21} // namespace synapse