File indexing completed on 2025-08-03 08:16:40
0001
0002
0003 #ifndef FFAMODULES_CDBINTERFACE_H
0004 #define FFAMODULES_CDBINTERFACE_H
0005
0006 #include <fun4all/SubsysReco.h>
0007
0008 #include <cstdint> // for uint64_t
0009 #include <set>
0010 #include <string>
0011 #include <tuple> // for tuple
0012
0013 class PHCompositeNode;
0014 class SphenixClient;
0015
0016 class CDBInterface : public SubsysReco
0017 {
0018 public:
0019 static CDBInterface *instance();
0020
0021 ~CDBInterface() override;
0022
0023
0024 int End(PHCompositeNode *topNode) override;
0025
0026 void Print(const std::string &what = "ALL") const override;
0027
0028 void Disable() { disable = true; }
0029 void Enable() { disable = false; }
0030
0031 void Disable_default() { disable_default = true; }
0032 void Enable_default() { disable_default = false; }
0033
0034 std::string getUrl(const std::string &domain, const std::string &filename = "");
0035
0036 private:
0037 CDBInterface(const std::string &name = "CDBInterface");
0038
0039 static CDBInterface *__instance;
0040 SphenixClient *cdbclient{nullptr};
0041 bool disable{false};
0042 bool disable_default{false};
0043 std::set<std::tuple<std::string, std::string, uint64_t>> m_UrlVector;
0044 };
0045
0046 #endif