12#ifndef RTCTK_COMPONENTFRAMEWORK_PERSISTENTREPOADAPTER_HPP
13#define RTCTK_COMPONENTFRAMEWORK_PERSISTENTREPOADAPTER_HPP
21#include <mal/utility/Uri.hpp>
81 elt::mal::Uri
GetUri()
const override {
82 return m_path_mapper.GetBaseUri();
93 return m_fits_write_threshold;
101 m_fits_write_threshold = value;
105 template <
typename T>
108 template <
typename T>
111 template <
typename T>
114 template <
typename T>
117 template <
typename T>
128 BatchResponse ProcessRequests(
const RequestList& requests)
override;
152 template <
typename T>
153 static void CheckBufferAndDataPointTypesMatch(
const std::type_info& type,
const T* node);
155 log4cplus::Logger& m_logger;
161 std::atomic<uint64_t> m_fits_write_threshold;
169 RTCTK_LOCAL static const std::type_info& LookupCppType(
const std::string& tag);
170 RTCTK_LOCAL static std::string LookupYamlTag(
const MetaData& metadata);
172 RTCTK_LOCAL static std::tuple<std::string, std::string, bool>
173 LookupYamlTags(
const MetaData& metadata);
175 using TagToTypeMap = std::unordered_map<std::string, const std::type_info&>;
176 using TypeToTagMap = std::unordered_map<std::type_index, std::pair<std::string, std::string>>;
179 static const TagToTypeMap S_TAG_TO_TYPE;
182 static const TypeToTagMap S_TYPE_TO_TAG;
184 template <
typename T>
185 static RequestDispatcher<PersistentRepoAdapter>::TableEntries BindTypeHandlers();
187 static const RequestDispatcher<PersistentRepoAdapter> S_REQUEST_DISPATCHER;
This class provides a wrapper for a data point path.
Definition dataPointPath.hpp:76
The DynamicThreadPool allows creating multiple threads which are garbage collected.
Definition dynamicThreadPool.hpp:36
Used to calculate URIs from datapoint paths.
Definition pathMapper.hpp:32
~PersistentRepoAdapter() override=default
PersistentRepoAdapter()=delete
Do not allow construction with no arguments.
PersistentRepoAdapter & operator=(PersistentRepoAdapter &&)=default
Objects of this class can be moved with the move assignment operator.
PersistentRepoAdapter & operator=(const PersistentRepoAdapter &)=delete
This class cannot be copy assigned.
PersistentRepoAdapter(const PersistentRepoAdapter &)=delete
This class cannot be copy constructed.
uint64_t GetFitsWriteThreshold() const
Return the number of elements above which matrices and vectors are written to FITS files.
Definition persistentRepoAdapter.hpp:92
PersistentRepoAdapter(PersistentRepoAdapter &&)=default
Objects of this class can be moved.
static const std::string SUPPORTED_URI_SCHEME
Definition persistentRepoAdapter.hpp:52
void SetFitsWriteThreshold(uint64_t value)
Set the number of elements above which matrices and vectors are written to FITS files.
Definition persistentRepoAdapter.hpp:100
elt::mal::Uri GetUri() const override
Get the URI used when creating this adapter object.
Definition persistentRepoAdapter.hpp:81
Base interface for all Persistent Configuration Repository adapters.
Definition persistentRepoIf.hpp:24
#define RTCTK_LOCAL
Helper to hide a class or function from the public symbol table.
Definition config.hpp:59
#define RTCTK_API
Helper to indicate that a class or function must be exported in the public symbol table.
Definition config.hpp:32
Header file for a dynamic resizing thread pool.
Provides macros and utilities for exception handling.
Logging Support Library based on log4cplus.
Definition commandReplier.cpp:21
RepositoryIf::MetaData MetaData
Definition oldbAdapter.cpp:57
RepositoryIf::PathList PathList
Definition persistentRepoAdapter.cpp:95
Header file declaring PathMapper.
Header file for PersistentRepoIf, which defines the API for PersistentRepoAdapter.
Header file for the RequestDispatcher utility class.
Definition repositoryIf.ipp:39
Definition repositoryIf.ipp:123
Definition repositoryIf.ipp:47
Definition repositoryIf.ipp:52
Definition repositoryIf.ipp:58
Definition repositoryIf.ipp:90
Definition repositoryIf.ipp:101
Definition repositoryIf.ipp:66
Definition repositoryIf.ipp:129
Definition repositoryIf.ipp:80