ChimeraTK-DeviceAccess-DoocsBackend 01.11.02
Loading...
Searching...
No Matches
CatalogueFetcher.h
Go to the documentation of this file.
1#pragma once
2
3#include "RegisterInfo.h"
4
5#include <future>
6#include <memory>
7#include <string>
8#include <utility>
9
11 public:
12 CatalogueFetcher(const std::string& serverAddress, std::future<void> cancelIndicator)
13 : serverAddress_(serverAddress), cancelFlag_(std::move(cancelIndicator)) {}
14
15 std::pair<DoocsBackendRegisterCatalogue, bool> fetch();
16
17 private:
18 std::string serverAddress_;
19 std::future<void> cancelFlag_;
21 bool locationLookupError_{false};
22 std::string _failedPropertyFirst;
23 std::string _failedPropertyError;
24 size_t _failedPropertyCount{0};
25
26 void fillCatalogue(std::string fixedComponents, long level);
27 bool isCancelled() const { return (cancelFlag_.wait_for(std::chrono::microseconds(0)) == std::future_status::ready); }
28 bool checkZmqAvailability(const std::string& fullQualifiedName) const;
29};
std::pair< DoocsBackendRegisterCatalogue, bool > fetch()
CatalogueFetcher(const std::string &serverAddress, std::future< void > cancelIndicator)