File indexing completed on 2024-04-06 12:12:59
0001 #ifndef FWCore_PluginManager_PluginCapabilities_h
0002 #define FWCore_PluginManager_PluginCapabilities_h
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022 #include <map>
0023 #include <string>
0024
0025
0026 #include "FWCore/PluginManager/interface/PluginFactoryBase.h"
0027
0028
0029 namespace edmplugin {
0030 class SharedLibrary;
0031 class DummyFriend;
0032 class PluginCapabilities : public PluginFactoryBase {
0033 friend class DummyFriend;
0034
0035 public:
0036 PluginCapabilities(const PluginCapabilities&) = delete;
0037 const PluginCapabilities& operator=(const PluginCapabilities&) = delete;
0038 ~PluginCapabilities() override;
0039
0040
0041 std::vector<PluginInfo> available() const override;
0042 const std::string& category() const override;
0043
0044
0045 static PluginCapabilities* get();
0046
0047
0048 void load(const std::string& iName);
0049
0050
0051 bool tryToLoad(const std::string& iName);
0052
0053
0054 bool tryToFind(const SharedLibrary& iLoadable);
0055
0056 private:
0057 PluginCapabilities();
0058
0059
0060 std::map<std::string, std::filesystem::path> classToLoadable_;
0061 };
0062
0063 }
0064 #endif