13#ifndef RTCTK_COMPONENTFRAMEWORK_OLDBADAPTER_HPP
14#define RTCTK_COMPONENTFRAMEWORK_OLDBADAPTER_HPP
19#include <ciiOldbSubscription.hpp>
20#include <ciiOldbTypedDataBase.hpp>
101 template <
typename T>
103 const std::shared_ptr<elt::oldb::CiiOldbTypedDataBase>&);
112 mutable std::shared_ptr<elt::oldb::CiiOldb>
m_client;
119 std::shared_ptr<elt::oldb::CiiOldbTypedDataBase>
dp;
120 std::shared_ptr<elt::oldb::CiiOldbDpSubscriptionBase>
sub;
126 using LookupTable = std::unordered_map<std::type_index, DispatchFunction>;
129 template <
typename T>
This class provides a wrapper for a data point path.
Definition dataPointPath.hpp:74
Implementation of the OLDB Adapter.
Definition oldbAdapter.hpp:29
void GetChildrenImpl(detail::GetChildrenRequest &)
Definition oldbAdapter.cpp:1249
std::unordered_map< std::type_index, DispatchFunction > LookupTable
Definition oldbAdapter.hpp:126
void WriteImpl(detail::WriteRequest< T > &)
Definition oldbAdapter.cpp:629
void GetChildrenImplRecursive(const DataPointPath &, PathList &, PathList &, bool)
Definition oldbAdapter.cpp:1259
void UnsubscribeImpl(detail::UnsubscribeRequest &)
Definition oldbAdapter.cpp:1544
void AddSubscription(detail::ValueSubscribeRequest &, const std::shared_ptr< elt::oldb::CiiOldbTypedDataBase > &)
void CreateLinkImpl(detail::CreateSymlinkRequest &)
Definition oldbAdapter.cpp:1286
OldbAdapter(const OldbAdapter &)=delete
This class cannot be copy constructed.
static const LookupTable S_REQUEST_DISPATCHER_TABLE
Definition oldbAdapter.hpp:132
const elt::mal::Uri m_baseuri
The prefix part for OLDB URIs.
Definition oldbAdapter.hpp:109
OldbAdapter & operator=(const OldbAdapter &)=delete
This class cannot be copy assigned.
static const std::string SUPPORTED_URI_SCHEME
Definition oldbAdapter.hpp:31
OldbAdapter()=delete
Do not allow construction with no arguments.
std::map< SubscriptionId, SubscriptionEntry > m_subscriptions
Definition oldbAdapter.hpp:123
void WriteMetaDataImpl(detail::WriteMetaDataRequest &)
operation partially supported by this backend, limited metadata functionality
Definition oldbAdapter.cpp:725
std::function< void(OldbAdapter *, std::any &)> DispatchFunction
Definition oldbAdapter.hpp:125
void CreateImpl(detail::CreateRequest< T > &)
Definition oldbAdapter.cpp:596
BatchResponse ProcessRequests(const RequestList &requests) override
Definition oldbAdapter.cpp:1553
virtual void InvokeRequestHandler(std::any &)
Definition oldbAdapter.cpp:1594
void UpdateLinkImpl(detail::UpdateSymlinkRequest &)
operation not supported by this backend, invocation will result in exception
Definition oldbAdapter.cpp:1313
void PartialReadImpl(detail::PartialReadRequest< T > &)
operation not supported by this backend, invocation will result in exception
Definition oldbAdapter.cpp:929
virtual ~OldbAdapter()
Definition oldbAdapter.cpp:592
OldbAdapter & operator=(OldbAdapter &&)=default
Objects of this class can be moved with the move assignment operator.
static TableEntry Bind(void(OldbAdapter::*method)(T &))
Definition oldbAdapter.cpp:1604
void ExistsImpl(detail::ExistsRequest &)
Definition oldbAdapter.cpp:1225
void PartialWriteImpl(detail::PartialWriteRequest< T > &)
operation not supported by this backend, invocation will result in exception
Definition oldbAdapter.cpp:721
void CreateDeleteSubscribeImpl(detail::CreateDeleteSubscribeRequest &)
operation not supported by this backend, invocation will result in exception
Definition oldbAdapter.cpp:1540
void ReadMetaDataImpl(detail::ReadMetaDataRequest &)
operation partially supported by this backend, limited metadata functionality
Definition oldbAdapter.cpp:933
std::mutex m_mutex
Mutex for synchronising access to subscriptions.
Definition oldbAdapter.hpp:115
typename LookupTable::value_type TableEntry
Definition oldbAdapter.hpp:127
OldbAdapter(OldbAdapter &&)=default
Objects of this class can be moved.
std::shared_ptr< elt::oldb::CiiOldb > m_client
Pointer to the CII OLDB API client object.
Definition oldbAdapter.hpp:112
void DeleteImpl(detail::DeleteRequest &)
Definition oldbAdapter.cpp:1065
void SubscribeImpl(detail::ValueSubscribeRequest &)
Definition oldbAdapter.cpp:1414
void ReadImpl(detail::ReadRequest< T > &)
Definition oldbAdapter.cpp:858
Base interface for all OLDB adapters.
Definition oldbIf.hpp:25
Definition repositoryIf.hpp:920
std::vector< std::any > RequestList
Definition repositoryIf.hpp:106
Definition commandReplier.cpp:22
RepositoryIf::PathList PathList
Definition oldbAdapterLegacy.cpp:322
elt::mal::future< std::string > InjectReqRepEvent(StateMachineEngine &engine)
Definition malEventInjector.hpp:23
Header file for OldbIf, which defines the API for OldbAdapters.
Definition oldbAdapter.hpp:118
std::function< void(SubscriptionEntry &) unreg_cb)
Definition oldbAdapter.hpp:121
std::shared_ptr< elt::oldb::CiiOldbDpSubscriptionBase > sub
Definition oldbAdapter.hpp:120
std::shared_ptr< elt::oldb::CiiOldbTypedDataBase > dp
Definition oldbAdapter.hpp:119
Definition repositorySubscriberIf.ipp:34
Definition repositoryIf.ipp:36
Definition repositoryIf.ipp:118
Definition repositoryIf.ipp:44
Definition repositoryIf.ipp:49
Definition repositoryIf.ipp:55
Definition repositoryIf.ipp:86
Definition repositoryIf.ipp:97
Definition repositoryIf.ipp:63
Definition repositorySubscriberIf.ipp:41
Definition repositoryIf.ipp:124
Definition repositorySubscriberIf.ipp:27
Definition repositoryIf.ipp:77