CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
PluginCapabilities.h
Go to the documentation of this file.
1 #ifndef FWCore_PluginManager_PluginCapabilities_h
2 #define FWCore_PluginManager_PluginCapabilities_h
3 // -*- C++ -*-
4 //
5 // Package: PluginManager
6 // Class : PluginCapabilities
7 //
16 //
17 // Original Author: Chris Jones
18 // Created: Fri Apr 6 12:36:19 EDT 2007
19 //
20 
21 // system include files
22 #include <map>
23 #include <string>
24 
25 // user include files
27 // forward declarations
28 
29 namespace edmplugin {
30  class SharedLibrary;
31  class DummyFriend;
33 {
34  friend class DummyFriend;
35  public:
36  virtual ~PluginCapabilities();
37 
38  // ---------- const member functions ---------------------
39  virtual std::vector<PluginInfo> available() const;
40  virtual const std::string& category() const;
41 
42  // ---------- static member functions --------------------
43  static PluginCapabilities* get();
44 
45  // ---------- member functions ---------------------------
46  void load(const std::string& iName);
47 
48  //returns false if loading fails because iName is unknown
49  bool tryToLoad(const std::string& iName);
50 
52  bool tryToFind(const SharedLibrary& iLoadable);
53 
54  private:
56  PluginCapabilities(const PluginCapabilities&); // stop default
57 
58  const PluginCapabilities& operator=(const PluginCapabilities&); // stop default
59 
60  // ---------- member data --------------------------------
61  std::map<std::string, boost::filesystem::path> classToLoadable_;
62 };
63 
64 }
65 #endif
bool tryToFind(const SharedLibrary &iLoadable)
Check to see if any capabilities are in the file, returns &#39;true&#39; if found.
virtual const std::string & category() const
returns the name of the category to which this plugin factory belongs
const PluginCapabilities & operator=(const PluginCapabilities &)
virtual std::vector< PluginInfo > available() const
return info about all plugins which are already available in the program
bool tryToLoad(const std::string &iName)
std::map< std::string, boost::filesystem::path > classToLoadable_
void load(const std::string &iName)