From 9951de18e9b54e3c2730fc3af9d0bc9edac1412c Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Thu, 3 Mar 2022 20:20:56 +0000 Subject: Make the database clients free to be used as variables, not just inheritted --- icetray/icetray/abstractCachingDatabaseClient.h | 2 +- icetray/icetray/abstractDatabaseClient.h | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/icetray/icetray/abstractCachingDatabaseClient.h b/icetray/icetray/abstractCachingDatabaseClient.h index c3d6ea3..e9e91e7 100644 --- a/icetray/icetray/abstractCachingDatabaseClient.h +++ b/icetray/icetray/abstractCachingDatabaseClient.h @@ -25,7 +25,7 @@ namespace IceTray { using CacheKey = std::vector; using CacheItem = std::any; - protected: + public: explicit AbstractCachingDatabaseClient(const DB::ConnectionPoolPtr & d); template diff --git a/icetray/icetray/abstractDatabaseClient.h b/icetray/icetray/abstractDatabaseClient.h index e798c2e..047eaee 100644 --- a/icetray/icetray/abstractDatabaseClient.h +++ b/icetray/icetray/abstractDatabaseClient.h @@ -19,7 +19,7 @@ namespace DB { namespace IceTray { class DLL_PUBLIC AbstractDatabaseClient { - protected: + public: explicit AbstractDatabaseClient(DB::ConnectionPoolPtr d); template @@ -54,6 +54,7 @@ namespace IceTray { return Slicer::DeserializeAny(s.get(), typeIdCol); } + protected: template static void inline bind(unsigned int offset, DB::Command * cmd, const Param & p, const Params &... params) { -- cgit v1.2.3