comparison checker.cpp @ 6:61dbb18f2369

Logging, timeouts
author Chris Cannam
date Wed, 13 Apr 2016 18:41:49 +0100
parents 74064d6f5e07
children
comparison
equal deleted inserted replaced
5:74064d6f5e07 6:61dbb18f2369
31 31
32 #include <iostream> 32 #include <iostream>
33 33
34 using namespace std; 34 using namespace std;
35 35
36 struct LogCallback : PluginCandidates::LogCallback {
37 virtual void log(string message) {
38 cerr << "checker: log: " << message;
39 }
40 };
41
36 int main(int, char **) 42 int main(int, char **)
37 { 43 {
38 KnownPlugins kp; 44 LogCallback cb;
39 45 KnownPlugins kp("./helper", &cb); //!!!
46
40 for (auto t: kp.getKnownPluginTypes()) { 47 for (auto t: kp.getKnownPluginTypes()) {
41 cout << "successful libraries for plugin type \"" 48 cout << "successful libraries for plugin type \""
42 << kp.getTagFor(t) << "\":" << endl; 49 << kp.getTagFor(t) << "\":" << endl;
43 for (auto lib: kp.getCandidateLibrariesFor(t)) { 50 for (auto lib: kp.getCandidateLibrariesFor(t)) {
44 cout << lib << endl; 51 cout << lib << endl;