not enough information... skip it
: no Configurable for this component. yet... continue;
{
const bool isGaudiSvc = (
std::find( libs.begin(), endLib, gaudiSvc ) != endLib );
cout <<
"ERROR: ApplicationMgr can not be created. Check environment" <<
endl;
}
Scope factories = Scope::ByName(PLUGINSVC_FACTORY_NS);
if ( !factories ) {
cout <<
"ERROR: No PluginSvc factory namespace could be found" <<
endl;
}
bool allGood = true;
if ( !isGaudiSvc ) {
for ( Member_Iterator it = factories.FunctionMember_Begin();
it != factories.FunctionMember_End(); ++it ) {
string ident =
getId(*it);
if ( PluginService::Debug() > 0 ) {
}
}
}
if ( err != 1 ) {
allGood = false;
continue;
}
for ( Member_Iterator it = factories.FunctionMember_Begin();
it != factories.FunctionMember_End();
++it ) {
const string ident =
getId(*it);
if ( bkgNames.
find(ident) != bkgNamesEnd ) {
if ( PluginService::Debug() > 0 ) {
cout <<
"\t==> skipping [" << ident <<
"]..." <<
endl;
}
continue;
}
cout <<
"WARNING: library [" << *iLib <<
"] requested factory "
<< "from another library ["
<< " ==> [" << ident << "] !!"
continue;
}
const string rtype = it->TypeOf().ReturnType().Name();
bool known = true;
if ( ident == "ApplicationMgr" ) type = "ApplicationMgr";
else if ( rtype == "IInterface*" ) type = "IInterface";
else if ( rtype == "IAlgorithm*" ) type = "Algorithm";
else if ( rtype == "IService*" ) type = "Service";
else if ( rtype == "IAlgTool*" ) type = "AlgTool";
else if ( rtype == "IAuditor*" ) type = "Auditor";
else if ( rtype == "IConverter*" ) type = "Converter";
else if ( rtype == "DataObject*" ) type = "DataObject";
else type = "Unknown", known = false;
string name = ident;
boost::trim(name);
cout <<
" - component: " << name <<
endl;
if ( type == "IInterface" ) {
continue;
}
if ( type == "Converter" || type == "DataObject" ) {
continue;
}
if ( !known ) {
cout <<
"WARNING: Unknown (return) type [" << rtype <<
"] !!\n"
<< "WARNING: component [" << ident << "] is skipped !"
<< endl;
allGood = false;
continue;
}
string cname = "DefaultName";
if ( type == "AlgTool" ) {
args[0] = &cname;
args[2] = dummySvc;
}
else {
args[0] = &cname;
args[1] = svcLoc;
}
try {
if ( type == "Algorithm" ) {
prop = makeInstance<IAlgorithm>(*it,
args);
}
else if ( type == "Service") {
prop = makeInstance<IService>(*it,
args);
}
else if ( type == "AlgTool") {
prop = makeInstance<IAlgTool>(*it,
args);
}
else if ( type == "Auditor") {
prop = makeInstance<IAuditor>(*it,
args);
}
else if ( type == "ApplicationMgr") {
}
else {
prop = makeInstance<IInterface>(*it,
args);
}
}
cout <<
"ERROR: Error instantiating " << name
<< " from " << *iLib << endl;
cout <<
"ERROR: Got exception: " << e.
what() << endl;
allGood = false;
continue;
}
catch ( ... ) {
cout <<
"ERROR: Error instantiating " << name
<< " from " << *iLib << endl;
allGood = false;
continue;
}
if( prop ) {
allGood = false;
}
} else {
cout <<
"ERROR: could not cast IInterface* object to an IProperty* !\n"
<< "ERROR: return type from PluginSvc is [" << rtype << "]...\n"
<< "ERROR: NO Configurable will be generated for ["
<< name << "] !"
<< endl;
allGood = false;
}
}
fs::path(*iLib+
"_confDb.py") ).
string();
if (!userModule.empty())
py << "from " << userModule << " import *" <<endl;
}
dummySvc = 0;
}