00001 // -*- C++ -*- 00002 // 00003 // DynamicLoader.h is a part of ThePEG - Toolkit for HEP Event Generation 00004 // Copyright (C) 1999-2007 Leif Lonnblad 00005 // 00006 // ThePEG is licenced under version 2 of the GPL, see COPYING for details. 00007 // Please respect the MCnet academic guidelines, see GUIDELINES for details. 00008 // 00009 #ifndef ThePEG_DynamicLoader_H 00010 #define ThePEG_DynamicLoader_H 00011 // This is the declaration of the DynamicLoader class. 00012 00013 #include "ThePEG/Config/ThePEG.h" 00014 00015 namespace ThePEG { 00016 00027 class DynamicLoader { 00028 00029 public: 00030 00034 static bool loadcmd(string); 00035 00042 static bool load(string file); 00043 00048 static void appendPath(string); 00049 00054 static void prependPath(string); 00055 00059 static string lastErrorMessage; 00060 00065 static void dlname(string); 00066 00071 static string dlnameversion(string libs); 00072 00077 static const vector<string> & allPaths(); 00078 00083 static const vector<string> & appendedPaths(); 00084 00089 static const vector<string> & prependedPaths(); 00090 00091 private: 00092 00097 static vector<string> paths; 00098 00103 static vector<string> prepaths; 00104 00109 static vector<string> apppaths; 00110 00115 static vector<string> defaultPaths(); 00116 00121 static map<string,string> versionMap; 00122 00123 }; 00124 00125 } 00126 00127 #endif /* ThePEG_DynamicLoader_H */