Example of using Catalog
#include <iostream>
#include "boost/foreach.hpp"
int main(
int argc,
char* argv[]) {
owlcpp::Lib_info::print(std::cout << "find_owl\n" "built with ") << std::endl;
if( argc < 2 ) {
std::cout << "Usage: find_owl path1 [path2 ...]" << std::endl;
return 0;
}
try {
for(
int i = 1; i != argc; ++i)
add(cat, argv[i],
false, 100);
std::cout << "path" << '\t' << "ontologyIRI" << '\t' << "versionIRI" << '\n';
std::cout
<<
'\"' << cat.
path(
id) <<
"\"\t\""
<< cat.
ontology_iri_str(
id) <<
"\"\t\""
<< cat.
version_iri_str(
id) <<
"\"\n"
;
}
} catch(...) {
std::cerr << boost::current_exception_diagnostic_information() << std::endl;
return 1;
}
return 0;
}