blob: 16f6dc34db036fd491a56b9bbdf9663399a12d4e [file] [log] [blame]
Tomáš Pecka7acf3922021-08-10 11:16:57 +02001/*
2 * Copyright (C) 2020 CESNET, https://photonics.cesnet.cz/
3 *
4 * Written by Tomáš Pecka <tomas.pecka@fit.cvut.cz>
5 *
6 */
7
8#pragma once
9
10#include <functional>
11#include <map>
12#include <memory>
13#include <optional>
14#include <sysrepo-cpp/Session.hpp>
15#include "LLDP.h"
16#include "utils/log-fwd.h"
17
18namespace velia::system {
19
20class LLDPCallback {
21public:
22 explicit LLDPCallback(std::shared_ptr<LLDPDataProvider> lldp);
Václav Kubernát7efd6d52021-11-09 01:31:11 +010023 sysrepo::ErrorCode operator()(sysrepo::Session session, uint32_t subscriptionId, std::string_view moduleName, std::optional<std::string_view> subXPath, std::optional<std::string_view> requestXPath, uint32_t, std::optional<libyang::DataNode>& output);
Tomáš Pecka7acf3922021-08-10 11:16:57 +020024
25private:
26 velia::Log m_log;
27 std::shared_ptr<LLDPDataProvider> m_lldp;
Tomáš Pecka7acf3922021-08-10 11:16:57 +020028};
29
30}