The Gaudi Framework  v30r3 (a5ef0a68)
configGenerator Class Reference
Collaboration diagram for configGenerator:

Public Member Functions

 configGenerator (const string &pkgName, const string &outputDirName)
 
int genConfig (const Strings_t &modules, const string &userModule)
 main entry point of this class: More...
 
void setConfigurableModule (const std::string &moduleName)
 customize the Module name where configurable base classes are defined More...
 
void setConfigurableDefaultName (const std::string &defaultName)
 customize the default name for configurable instances More...
 
void setConfigurableAlgorithm (const std::string &cfgAlgorithm)
 customize the configurable base class for Algorithm component More...
 
void setConfigurableAlgTool (const std::string &cfgAlgTool)
 customize the configurable base class for AlgTool component More...
 
void setConfigurableAuditor (const std::string &cfgAuditor)
 customize the configurable base class for AlgTool component More...
 
void setConfigurableService (const std::string &cfgService)
 customize the configurable base class for Service component More...
 

Private Member Functions

bool genComponent (const std::string &libName, const std::string &componentName, component_t componentType, const vector< PropertyBase * > &properties)
 
void genImport (std::ostream &s, const boost::format &frmt, std::string indent)
 
void genHeader (std::ostream &pyOut, std::ostream &dbOut)
 
void genBody (std::ostream &pyOut, std::ostream &dbOut)
 
void genTrailer (std::ostream &pyOut, std::ostream &dbOut)
 
void pythonizeValue (const PropertyBase *prop, string &pvalue, string &ptype)
 handle the "marshalling" of Properties More...
 

Private Attributes

string m_pkgName
 name of the package we are processing More...
 
string m_outputDirName
 absolute path to the directory where genconf will store auto-generated files (Configurables and ConfigurableDb) More...
 
stringstream m_pyBuf
 buffer of auto-generated configurables More...
 
bool m_importGaudiHandles = false
 switch to decide if the generated configurables need to import GaudiHandles (ie: if one of the components has a XyzHandle<T>) More...
 
bool m_importDataObjectHandles = false
 
stringstream m_dbBuf
 buffer of generated configurables informations for the "Db" file The "Db" file is holding informations about the generated configurables This file is later one used by the PropertyProxy.py to locate Configurables and know their default values, host module,... More...
 
std::map< component_t, std::stringm_configurable
 Configurable customization. More...
 

Detailed Description

Definition at line 159 of file genconf.cpp.

Constructor & Destructor Documentation

configGenerator::configGenerator ( const string pkgName,
const string outputDirName 
)
inline

Definition at line 190 of file genconf.cpp.

191  : m_pkgName( pkgName ), m_outputDirName( outputDirName )
192  {
193  }
string m_outputDirName
absolute path to the directory where genconf will store auto-generated files (Configurables and Confi...
Definition: genconf.cpp:166
string m_pkgName
name of the package we are processing
Definition: genconf.cpp:162

Member Function Documentation

void configGenerator::genBody ( std::ostream pyOut,
std::ostream dbOut 
)
inlineprivate

Definition at line 234 of file genconf.cpp.

235  {
236  pyOut << m_pyBuf.str() << flush;
237  dbOut << m_dbBuf.str() << flush;
238  }
stringstream m_pyBuf
buffer of auto-generated configurables
Definition: genconf.cpp:169
T str(T...args)
stringstream m_dbBuf
buffer of generated configurables informations for the "Db" file The "Db" file is holding information...
Definition: genconf.cpp:180
T flush(T...args)
bool configGenerator::genComponent ( const std::string libName,
const std::string componentName,
component_t  componentType,
const vector< PropertyBase * > &  properties 
)
private

Definition at line 682 of file genconf.cpp.

685 {
686  auto cname = pythonizeName( componentName );
687 
689  propDoc.reserve( properties.size() );
690 
691  m_pyBuf << "\nclass " << cname << "( " << m_configurable[componentType] << " ) :\n";
692  m_pyBuf << " __slots__ = { \n";
693  for ( const auto& prop : properties ) {
694  const string& pname = prop->name();
695  // Validate property name (it must be a valid Python identifier)
696  if ( !boost::regex_match( pname, pythonIdentifier ) ) {
697  std::cout << "ERROR: invalid property name \"" << pname << "\" in component " << cname
698  << " (invalid Python identifier)" << std::endl;
699  // try to make the buffer at least more or less valid python code.
700  m_pyBuf << " #ERROR-invalid identifier '" << pname << "'\n"
701  << " }\n";
702  return false;
703  }
704 
705  string pvalue, ptype;
706  pythonizeValue( prop, pvalue, ptype );
707  m_pyBuf << " '" << pname << "' : " << pvalue << ", # " << ptype << "\n";
708 
709  if ( prop->documentation() != "none" ) {
710  propDoc.emplace_back( pname, prop->documentation() + " [" + prop->ownerTypeName() + "]" );
711  }
712  }
713  m_pyBuf << " }\n";
714  m_pyBuf << " _propertyDocDct = { \n";
715  for ( const auto& prop : propDoc ) {
716  m_pyBuf << std::setw( 5 ) << "'" << prop.first << "' : "
717  << "\"\"\" " << prop.second << " \"\"\",\n";
718  }
719  m_pyBuf << " }\n";
720 
721  m_pyBuf << " def __init__(self, name = " << m_configurable[component_t::DefaultName] << ", **kwargs):\n"
722  << " super(" << cname << ", self).__init__(name)\n"
723  << " for n,v in kwargs.items():\n"
724  << " setattr(self, n, v)\n"
725  << " def getDlls( self ):\n"
726  << " return '" << libName << "'\n"
727  << " def getType( self ):\n"
728  << " return '" << componentName << "'\n"
729  << " pass # class " << cname << "\n"
730  << flush;
731 
732  // name of the auto-generated module
733  const string pyName = ( fs::path( m_outputDirName ) / fs::path( libName + "Conf.py" ) ).string();
734  const string modName = fs::basename( fs::path( pyName ).leaf() );
735 
736  // now the db part
737  m_dbBuf << m_pkgName << "." << modName << " " << libName << " " << cname << "\n" << flush;
738 
739  return true;
740 }
T endl(T...args)
stringstream m_pyBuf
buffer of auto-generated configurables
Definition: genconf.cpp:169
T setw(T...args)
stringstream m_dbBuf
buffer of generated configurables informations for the "Db" file The "Db" file is holding information...
Definition: genconf.cpp:180
T flush(T...args)
T size(T...args)
string m_outputDirName
absolute path to the directory where genconf will store auto-generated files (Configurables and Confi...
Definition: genconf.cpp:166
STL class.
void pythonizeValue(const PropertyBase *prop, string &pvalue, string &ptype)
handle the "marshalling" of Properties
Definition: genconf.cpp:743
std::map< component_t, std::string > m_configurable
Configurable customization.
Definition: genconf.cpp:187
string m_pkgName
name of the package we are processing
Definition: genconf.cpp:162
T reserve(T...args)
T emplace_back(T...args)
int configGenerator::genConfig ( const Strings_t modules,
const string userModule 
)

main entry point of this class:

  • iterate over all the modules (ie: library names)
  • for each module extract component informations
  • eventually generate the header/body/trailer python file and "Db" file

write-out files for this library

Definition at line 454 of file genconf.cpp.

456 {
457  //--- Disable checking StatusCode -------------------------------------------
459 
460  const auto endLib = libs.end();
461 
462  static const std::string gaudiSvc = "GaudiCoreSvc";
463  const bool isGaudiSvc = ( std::find( libs.begin(), endLib, gaudiSvc ) != endLib );
464 
465  //--- Instantiate ApplicationMgr --------------------------------------------
466  if ( !isGaudiSvc && createAppMgr() ) {
467  cout << "ERROR: ApplicationMgr can not be created. Check environment" << endl;
468  return EXIT_FAILURE;
469  }
470 
471  //--- Iterate over component factories --------------------------------------
472  using Gaudi::PluginService::Details::Registry;
473  const Registry& registry = Registry::instance();
474 
475  auto bkgNames = registry.loadedFactoryNames();
476 
477  ISvcLocator* svcLoc = Gaudi::svcLocator();
478  IInterface* dummySvc = new Service( "DummySvc", svcLoc );
479  dummySvc->addRef();
480 
481  bool allGood = true;
482 
483  // iterate over all the requested libraries
484  for ( const auto& iLib : libs ) {
485 
486  LOG_INFO << ":::: processing library: " << iLib << "...";
487 
488  // reset state
489  m_importGaudiHandles = false;
491  m_pyBuf.str( "" );
492  m_dbBuf.str( "" );
493 
494  //--- Load component library ----------------------------------------------
495  System::ImageHandle handle;
496  unsigned long err = System::loadDynamicLib( iLib, &handle );
497  if ( err != 1 ) {
499  allGood = false;
500  continue;
501  }
502 
503  const auto& factories = registry.factories();
504  for ( const auto& factoryName : registry.loadedFactoryNames() ) {
505  if ( bkgNames.find( factoryName ) != bkgNames.end() ) {
507  LOG_INFO << "\t==> skipping [" << factoryName << "]...";
508  }
509  continue;
510  }
511  auto entry = factories.find( factoryName );
512  if ( entry == end( factories ) ) {
513  LOG_ERROR << "inconsistency in component factories list: I cannot find anymore " << factoryName;
514  continue;
515  }
516  const auto& info = entry->second;
517  if ( !info.is_set() ) continue;
518 
519  // do not generate configurables for the Reflex-compatible aliases
520  if ( !info.getprop( "ReflexName" ).empty() ) continue;
521 
522  // Atlas contributed code (patch #1247)
523  // Skip the generation of configurables if the component does not come
524  // from the same library we are processing (i.e. we found a symbol that
525  // is coming from a library loaded by the linker).
526  if ( libNativeName( iLib ) != info.library ) {
527  LOG_WARNING << "library [" << iLib << "] exposes factory [" << factoryName << "] which is declared in ["
528  << info.library << "] !!";
529  continue;
530  }
531 
532  component_t type = component_t::Unknown;
533  {
534  const auto ft = allowedFactories.find( info.factory.type().name() );
535  if ( ft != allowedFactories.end() ) {
536  type = ft->second;
537  } else if ( factoryName == "ApplicationMgr" ) {
538  type = component_t::ApplicationMgr;
539  } else
540  continue;
541  }
542 
543  // handle possible problems with templated components
544  std::string name = boost::trim_copy( factoryName );
545 
546  const auto className = info.getprop( "ClassName" );
547  LOG_INFO << " - component: " << className << " (" << ( className != name ? ( name + ": " ) : std::string() )
548  << type << ")";
549 
550  string cname = "DefaultName";
551  SmartIF<IProperty> prop;
552  try {
553  switch ( type ) {
554  case component_t::Algorithm:
555  prop = SmartIF<IAlgorithm>( Algorithm::Factory::create( factoryName, cname, svcLoc ).release() );
556  break;
557  case component_t::Service:
558  prop = SmartIF<IService>( Service::Factory::create( factoryName, cname, svcLoc ).release() );
559  break;
560  case component_t::AlgTool:
561  prop =
562  SmartIF<IAlgTool>( AlgTool::Factory::create( factoryName, cname, toString( type ), dummySvc ).release() );
563  // FIXME: AlgTool base class increase artificially by 1 the refcount.
564  prop->release();
565  break;
566  case component_t::Auditor:
567  prop = SmartIF<IAuditor>( Auditor::Factory::create( factoryName, cname, svcLoc ).release() );
568  break;
569  case component_t::ApplicationMgr:
570  prop = SmartIF<ISvcLocator>( svcLoc );
571  break;
572  default:
573  continue; // unknown
574  }
575  } catch ( exception& e ) {
576  LOG_ERROR << "Error instantiating " << name << " from " << iLib;
577  LOG_ERROR << "Got exception: " << e.what();
578  allGood = false;
579  continue;
580  } catch ( ... ) {
581  LOG_ERROR << "Error instantiating " << name << " from " << iLib;
582  allGood = false;
583  continue;
584  }
585  if ( prop ) {
586  if ( !genComponent( iLib, name, type, prop->getProperties() ) ) {
587  allGood = false;
588  }
589  prop.reset();
590  } else {
591  LOG_ERROR << "could not cast IInterface* object to an IProperty* !";
592  LOG_ERROR << "NO Configurable will be generated for [" << name << "] !";
593  allGood = false;
594  }
595  } //> end loop over factories
596 
600  const std::string pyName = ( fs::path( m_outputDirName ) / fs::path( iLib + "Conf.py" ) ).string();
601  const std::string dbName = ( fs::path( m_outputDirName ) / fs::path( iLib + ".confdb" ) ).string();
602 
603  std::fstream py( pyName, std::ios_base::out | std::ios_base::trunc );
604  std::fstream db( dbName, std::ios_base::out | std::ios_base::trunc );
605 
606  genHeader( py, db );
607  if ( !userModule.empty() ) py << "from " << userModule << " import *" << endl;
608  genBody( py, db );
609  genTrailer( py, db );
610 
611  } //> end loop over libraries
612 
613  dummySvc->release();
614  dummySvc = 0;
615 
616  return allGood ? EXIT_SUCCESS : EXIT_FAILURE;
617 }
T empty(T...args)
The ISvcLocator is the interface implemented by the Service Factory in the Application Manager to loc...
Definition: ISvcLocator.h:25
component_t
Definition: genconf.cpp:96
#define LOG_ERROR
Definition: genconf.cpp:73
T endl(T...args)
void * ImageHandle
Definition of an image handle.
Definition: ModuleInfo.h:31
stringstream m_pyBuf
buffer of auto-generated configurables
Definition: genconf.cpp:169
STL class.
bool m_importDataObjectHandles
Definition: genconf.cpp:174
GAUDI_API ISvcLocator * svcLocator()
GAUDIPS_API Logger & logger()
Return the current logger instance.
T what(T...args)
#define LOG_INFO
Definition: genconf.cpp:75
Definition of the basic interface.
Definition: IInterface.h:277
STL class.
void genHeader(std::ostream &pyOut, std::ostream &dbOut)
Definition: genconf.cpp:651
T str(T...args)
stringstream m_dbBuf
buffer of generated configurables informations for the "Db" file The "Db" file is holding information...
Definition: genconf.cpp:180
STL class.
virtual const std::vector< Gaudi::Details::PropertyBase * > & getProperties() const =0
Get list of properties.
T find(T...args)
string m_outputDirName
absolute path to the directory where genconf will store auto-generated files (Configurables and Confi...
Definition: genconf.cpp:166
virtual unsigned long release()=0
Release Interface instance.
#define LOG_WARNING
Definition: genconf.cpp:74
bool m_importGaudiHandles
switch to decide if the generated configurables need to import GaudiHandles (ie: if one of the compon...
Definition: genconf.cpp:173
virtual unsigned long addRef()=0
Increment the reference count of Interface instance.
static GAUDI_API void disableChecking()
Definition: StatusCode.cpp:42
void reset(TYPE *ptr=nullptr)
Set the internal pointer to the passed one disposing of the old one.
Definition: SmartIF.h:92
void genTrailer(std::ostream &pyOut, std::ostream &dbOut)
Definition: genconf.cpp:674
GAUDI_API const std::string getLastErrorString()
Get last system error as string.
Definition: System.cpp:294
bool genComponent(const std::string &libName, const std::string &componentName, component_t componentType, const vector< PropertyBase * > &properties)
Definition: genconf.cpp:682
Base class for all services.
Definition: Service.h:36
int createAppMgr()
Definition: genconf.cpp:803
void genBody(std::ostream &pyOut, std::ostream &dbOut)
Definition: genconf.cpp:234
std::string toString(const Type &)
GAUDI_API unsigned long loadDynamicLib(const std::string &name, ImageHandle *handle)
Load dynamic link library.
Definition: System.cpp:154
void configGenerator::genHeader ( std::ostream pyOut,
std::ostream dbOut 
)
private

Definition at line 651 of file genconf.cpp.

653 {
654  // python file part
655  std::string now = Gaudi::Time::current().format( true );
656  py << "#" << now //<< "\n"
657  << "\"\"\"Automatically generated. DO NOT EDIT please\"\"\"\n";
658  if ( m_importGaudiHandles ) {
659  py << "from GaudiKernel.GaudiHandles import *\n";
660  }
661 
663  py << "from GaudiKernel.DataObjectHandleBase import DataObjectHandleBase\n";
664  }
665 
666  genImport( py, boost::format( "from %1%.Configurable import *" ) );
667 
668  // db file part
669  db << "## -*- ascii -*- \n"
670  << "# db file automatically generated by genconf on: " << now << "\n"
671  << flush;
672 }
GAUDI_API std::string format(const char *,...)
MsgStream format utility "a la sprintf(...)".
Definition: MsgStream.cpp:120
static Time current()
Returns the current time.
Definition: Time.cpp:112
STL class.
bool m_importDataObjectHandles
Definition: genconf.cpp:174
T flush(T...args)
void genImport(std::ostream &s, const boost::format &frmt, std::string indent)
Definition: genconf.cpp:619
bool m_importGaudiHandles
switch to decide if the generated configurables need to import GaudiHandles (ie: if one of the compon...
Definition: genconf.cpp:173
std::string format(bool local, std::string spec="%c") const
Format the time using strftime.
Definition: Time.cpp:260
void configGenerator::genImport ( std::ostream s,
const boost::format frmt,
std::string  indent = "" 
)
private

Definition at line 619 of file genconf.cpp.

620 {
621 
622  std::string::size_type pos = 0, nxtpos = 0;
624 
625  while ( std::string::npos != pos ) {
626  // find end of module name
627  nxtpos = m_configurable[component_t::Module].find_first_of( ',', pos );
628 
629  // Prepare import string
630  mod = m_configurable[component_t::Module].substr( pos, nxtpos - pos );
631  std::ostringstream import;
632  import << boost::format( frmt ) % mod;
633 
634  // append a normal import or a try/except enclosed one depending
635  // on availability of a fall-back module (next in the list)
636  if ( std::string::npos == nxtpos ) {
637  // last possible module
638  s << indent << import.str() << "\n" << flush;
639  pos = std::string::npos;
640  } else {
641  // we have a fallback for this
642  s << indent << "try:\n" << indent << py_tab << import.str() << "\n" << indent << "except ImportError:\n" << flush;
643  pos = nxtpos + 1;
644  }
645  // increase indentation level for next iteration
646  indent += py_tab;
647  }
648 }
GAUDI_API std::string format(const char *,...)
MsgStream format utility "a la sprintf(...)".
Definition: MsgStream.cpp:120
STL class.
T flush(T...args)
std::map< component_t, std::string > m_configurable
Configurable customization.
Definition: genconf.cpp:187
void configGenerator::genTrailer ( std::ostream pyOut,
std::ostream dbOut 
)
private

Definition at line 674 of file genconf.cpp.

676 {
677  // db file part
678  db << "## " << m_pkgName << "\n" << std::flush;
679 }
T flush(T...args)
string m_pkgName
name of the package we are processing
Definition: genconf.cpp:162
void configGenerator::pythonizeValue ( const PropertyBase prop,
string pvalue,
string ptype 
)
private

handle the "marshalling" of Properties

Definition at line 743 of file genconf.cpp.

745 {
746  const std::string cvalue = p->toString();
747  const std::type_index ti = std::type_index( *p->type_info() );
748  if ( ti == typeIndex<bool>() ) {
749  pvalue = ( cvalue == "0" || cvalue == "False" || cvalue == "false" ) ? "False" : "True";
750  ptype = "bool";
751  } else if ( ti == typeIndex<char>() || ti == typeIndex<signed char>() || ti == typeIndex<unsigned char>() ||
752  ti == typeIndex<short>() || ti == typeIndex<unsigned short>() || ti == typeIndex<int>() ||
753  ti == typeIndex<unsigned int>() || ti == typeIndex<long>() || ti == typeIndex<unsigned long>() ) {
754  pvalue = cvalue;
755  ptype = "int";
756  } else if ( ti == typeIndex<long long>() || ti == typeIndex<unsigned long long>() ) {
757  pvalue = cvalue + "L";
758  ptype = "long";
759  } else if ( ti == typeIndex<float>() || ti == typeIndex<double>() ) {
760  // forces python to handle this as a float: put a dot in there...
761  pvalue = boost::to_lower_copy( cvalue );
762  if ( pvalue == "nan" ) {
763  pvalue = "float('nan')";
764  std::cout << "WARNING: default value for [" << p->name() << "] is NaN !!" << std::endl;
765  } else if ( std::string::npos == pvalue.find( "." ) && std::string::npos == pvalue.find( "e" ) ) {
766  pvalue = cvalue + ".0";
767  }
768  ptype = "float";
769  } else if ( ti == typeIndex<string>() ) {
770  pvalue = "'" + cvalue + "'";
771  ptype = "str";
772  } else if ( ti == typeIndex<GaudiHandleBase>() ) {
773  const GaudiHandleProperty& hdl = dynamic_cast<const GaudiHandleProperty&>( *p );
774  const GaudiHandleBase& base = hdl.value();
775 
776  pvalue = base.pythonRepr();
777  ptype = "GaudiHandle";
778  m_importGaudiHandles = true;
779  } else if ( ti == typeIndex<GaudiHandleArrayBase>() ) {
780  const GaudiHandleArrayProperty& hdl = dynamic_cast<const GaudiHandleArrayProperty&>( *p );
781  const GaudiHandleArrayBase& base = hdl.value();
782 
783  pvalue = base.pythonRepr();
784  ptype = "GaudiHandleArray";
785  m_importGaudiHandles = true;
786  } else if ( ti == typeIndex<DataObjectHandleBase>() ) {
787  const DataObjectHandleProperty& hdl = dynamic_cast<const DataObjectHandleProperty&>( *p );
788  const DataObjectHandleBase& base = hdl.value();
789 
790  pvalue = base.pythonRepr();
791  ptype = "DataObjectHandleBase";
793  } else {
794  std::ostringstream v_str;
795  v_str.setf( std::ios::showpoint ); // to correctly display floats
796  p->toStream( v_str );
797  pvalue = v_str.str();
798  ptype = "list";
799  }
800 }
T setf(T...args)
T endl(T...args)
DataObjectHandleProperty.h GaudiKernel/DataObjectHandleProperty.h.
STL class.
bool m_importDataObjectHandles
Definition: genconf.cpp:174
const GaudiHandleBase & value() const
Definition: Property.h:922
const GaudiHandleArrayBase & value() const
Definition: Property.h:962
std::string pythonRepr() const override
Python representation of array of handles, i.e.
Definition: GaudiHandle.cpp:86
T find(T...args)
Base class of array&#39;s of various gaudihandles.
Definition: GaudiHandle.h:354
DataObjectHandleBase GaudiKernel/DataObjectHandleBase.h.
std::string pythonRepr() const override
Python representation of handle, i.e.
Definition: GaudiHandle.cpp:53
bool m_importGaudiHandles
switch to decide if the generated configurables need to import GaudiHandles (ie: if one of the compon...
Definition: genconf.cpp:173
std::string pythonRepr() const override
const DataObjectHandleBase & value() const
Base class to handles to be used in lieu of naked pointers to various Gaudi components.
Definition: GaudiHandle.h:94
void configGenerator::setConfigurableAlgorithm ( const std::string cfgAlgorithm)
inline

customize the configurable base class for Algorithm component

Definition at line 211 of file genconf.cpp.

212  {
213  m_configurable[component_t::Algorithm] = cfgAlgorithm;
214  }
std::map< component_t, std::string > m_configurable
Configurable customization.
Definition: genconf.cpp:187
void configGenerator::setConfigurableAlgTool ( const std::string cfgAlgTool)
inline

customize the configurable base class for AlgTool component

Definition at line 217 of file genconf.cpp.

217 { m_configurable[component_t::AlgTool] = cfgAlgTool; }
std::map< component_t, std::string > m_configurable
Configurable customization.
Definition: genconf.cpp:187
void configGenerator::setConfigurableAuditor ( const std::string cfgAuditor)
inline

customize the configurable base class for AlgTool component

Definition at line 220 of file genconf.cpp.

220 { m_configurable[component_t::Auditor] = cfgAuditor; }
std::map< component_t, std::string > m_configurable
Configurable customization.
Definition: genconf.cpp:187
void configGenerator::setConfigurableDefaultName ( const std::string defaultName)
inline

customize the default name for configurable instances

Definition at line 205 of file genconf.cpp.

206  {
207  m_configurable[component_t::DefaultName] = defaultName;
208  }
std::map< component_t, std::string > m_configurable
Configurable customization.
Definition: genconf.cpp:187
void configGenerator::setConfigurableModule ( const std::string moduleName)
inline

customize the Module name where configurable base classes are defined

Definition at line 202 of file genconf.cpp.

202 { m_configurable[component_t::Module] = moduleName; }
GAUDI_API const std::string & moduleName()
Get the name of the (executable/DLL) file without file-type.
Definition: ModuleInfo.cpp:54
std::map< component_t, std::string > m_configurable
Configurable customization.
Definition: genconf.cpp:187
void configGenerator::setConfigurableService ( const std::string cfgService)
inline

customize the configurable base class for Service component

Definition at line 223 of file genconf.cpp.

224  {
225  m_configurable[component_t::Service] = cfgService;
226  m_configurable[component_t::ApplicationMgr] = cfgService;
227  }
std::map< component_t, std::string > m_configurable
Configurable customization.
Definition: genconf.cpp:187

Member Data Documentation

std::map<component_t, std::string> configGenerator::m_configurable
private

Configurable customization.

Contains customization for:

  • Name of the module where configurable base classes are defined
  • Name of the configurable base class for the Algorithm component
  • Name of the configurable base class for the AlgTool component
  • Name of the configurable base class for the Service component

Definition at line 187 of file genconf.cpp.

stringstream configGenerator::m_dbBuf
private

buffer of generated configurables informations for the "Db" file The "Db" file is holding informations about the generated configurables This file is later one used by the PropertyProxy.py to locate Configurables and know their default values, host module,...

Definition at line 180 of file genconf.cpp.

bool configGenerator::m_importDataObjectHandles = false
private

Definition at line 174 of file genconf.cpp.

bool configGenerator::m_importGaudiHandles = false
private

switch to decide if the generated configurables need to import GaudiHandles (ie: if one of the components has a XyzHandle<T>)

Definition at line 173 of file genconf.cpp.

string configGenerator::m_outputDirName
private

absolute path to the directory where genconf will store auto-generated files (Configurables and ConfigurableDb)

Definition at line 166 of file genconf.cpp.

string configGenerator::m_pkgName
private

name of the package we are processing

Definition at line 162 of file genconf.cpp.

stringstream configGenerator::m_pyBuf
private

buffer of auto-generated configurables

Definition at line 169 of file genconf.cpp.


The documentation for this class was generated from the following file: