Mercurial > hg > vamp-plugin-load-checker
comparison plugincandidates.h @ 4:6f891a9c6434
Make checker with hard-coded knowledge about various plugin types and paths; fix some process management problems
author | Chris Cannam |
---|---|
date | Wed, 13 Apr 2016 12:00:07 +0100 |
parents | 2288c1d05c28 |
children | 74064d6f5e07 |
comparison
equal
deleted
inserted
replaced
3:3bae396cf8e0 | 4:6f891a9c6434 |
---|---|
26 */ | 26 */ |
27 PluginCandidates(std::string helperExecutableName); | 27 PluginCandidates(std::string helperExecutableName); |
28 | 28 |
29 /** Scan the libraries found in the given plugin path (i.e. list | 29 /** Scan the libraries found in the given plugin path (i.e. list |
30 * of plugin directories), checking that the given descriptor | 30 * of plugin directories), checking that the given descriptor |
31 * function can be looked up in each. Store the results | 31 * symbol can be looked up in each. Store the results |
32 * internally, associated with the given (arbitrary) tag, for | 32 * internally, associated with the given (arbitrary) tag, for |
33 * later querying using getCandidateLibrariesFor() and | 33 * later querying using getCandidateLibrariesFor() and |
34 * getFailedLibrariesFor(). | 34 * getFailedLibrariesFor(). |
35 * | 35 * |
36 * Not thread-safe. | 36 * Not thread-safe. |
37 */ | 37 */ |
38 void scan(std::string tag, | 38 void scan(std::string tag, |
39 stringlist pluginPath, | 39 stringlist pluginPath, |
40 std::string descriptorFunctionName); | 40 std::string descriptorSymbolName); |
41 | 41 |
42 /** Return list of plugin library paths that were checked | 42 /** Return list of plugin library paths that were checked |
43 * successfully during the scan for the given tag. | 43 * successfully during the scan for the given tag. |
44 */ | 44 */ |
45 stringlist getCandidateLibrariesFor(std::string tag); | 45 stringlist getCandidateLibrariesFor(std::string tag) const; |
46 | 46 |
47 struct FailureRec { | 47 struct FailureRec { |
48 std::string library; | 48 std::string library; |
49 std::string message; | 49 std::string message; |
50 }; | 50 }; |
51 | 51 |
52 /** Return list of failure reports arising from the prior scan for | 52 /** Return list of failure reports arising from the prior scan for |
53 * the given tag. | 53 * the given tag. |
54 */ | 54 */ |
55 std::vector<FailureRec> getFailedLibrariesFor(std::string tag); | 55 std::vector<FailureRec> getFailedLibrariesFor(std::string tag) const; |
56 | 56 |
57 private: | 57 private: |
58 std::string m_helper; | 58 std::string m_helper; |
59 std::map<std::string, stringlist> m_candidates; | 59 std::map<std::string, stringlist> m_candidates; |
60 std::map<std::string, std::vector<FailureRec> > m_failures; | 60 std::map<std::string, std::vector<FailureRec> > m_failures; |