13 """ GaudiPython.Bindings module.
14 This module provides the basic bindings of the main Gaudi
15 components to Python. It is itself based on the ROOT cppyy
16 Python extension module.
18 from __future__
import absolute_import, print_function
51 from GaudiKernel
import ROOT6WorkAroundEnabled
54 with warnings.catch_warnings():
55 warnings.simplefilter(
"ignore")
58 if sys.version_info >= (3,):
70 from GaudiKernel.Proxy.Configurable
import Configurable, getNeededConfigurables
72 from .
import Pythonizations
81 gbl.gInterpreter.Declare(
'#include "Gaudi/Property.h"')
82 Helper = gbl.GaudiPython.Helper
83 StringProperty = gbl.Gaudi.Property(
"std::string")
84 StringPropertyRef = gbl.Gaudi.Property(
"std::string&")
85 GaudiHandleProperty = gbl.GaudiHandleProperty
86 GaudiHandleArrayProperty = gbl.GaudiHandleArrayProperty
87 DataObject = gbl.DataObject
88 SUCCESS = gbl.StatusCode(gbl.StatusCode.SUCCESS)
89 FAILURE = gbl.StatusCode(gbl.StatusCode.FAILURE)
91 if hasattr(cppyy,
"nullptr"):
92 nullptr = cppyy.nullptr
93 elif hasattr(gbl,
"nullptr"):
98 cppyy.gbl.gInterpreter.Declare(
101 namespace GaudiPython { namespace Helpers {
102 void setProperty(ISvcLocator* svcLoc, std::string key, std::string value) {
103 if ( !svcLoc ) throw std::runtime_error( "invalid ISvcLocator pointer" );
104 svcLoc->getOptsSvc().set(key, value);
111 for l
in [l
for l
in dir(Helper)
if re.match(
"^to.*Array$", l)]:
112 exec(
"%s = Helper.%s" % (l, l))
116 if hasattr(Helper,
"toArray"):
120 return getattr(Helper,
"toArray")
125 return getattr(Helper,
"toArray<%s>" % typ)
130 if hasattr(cppyy,
"libPyROOT"):
131 ROOT = cppyy.libPyROOT
134 makeNullPointer = ROOT.MakeNullPointer
135 setOwnership = ROOT.SetOwnership
139 warnings.warn(
"GaudiPython: " + message, DeprecationWarning, stacklevel=3)
146 """Helper class to obtain the adequate interface from a component
147 by using the Gaudi queryInterface() mechanism"""
158 if obj.queryInterface(self.
type.interfaceID(), ip).isSuccess():
162 "ERROR: queryInterface failed for", obj,
"interface:", self.
type
164 except Exception
as e:
168 "caught when retrieving interface",
175 traceback.print_stack()
187 InterfaceCast.__init__(self, t)
197 """Load an LCG dictionary"""
198 loadlib_return_code = Helper.loadDynamicLib(dict)
199 if loadlib_return_code == 1:
202 f
"Failed to load dictionary library {dict} (return code {loadlib_return_code})"
211 Function to retrieve a certain C++ class by name and to load dictionary if requested
215 from gaudimodule import getClass
216 # one knows that class is already loaded
217 AppMgr = getClass( 'ApplicationMgr' )
218 # one knows where to look for class, if not loaded yet
219 MCParticle = getClass( 'MCParticle' , 'EventDict' )
220 # one knows where to look for class, if not loaded yet
221 Vertex = getClass( 'Vertex' , ['EventDict', 'PhysEventDict'] )
224 if hasattr(gbl, name):
225 return getattr(gbl, name)
227 if type(libs)
is not list:
231 if hasattr(gbl, name):
232 return getattr(gbl, name)
241 """holds the value and the documentation string of a property"""
247 if issubclass(
type(prop), GaudiHandleProperty):
249 elif issubclass(
type(prop), GaudiHandleArrayProperty):
250 self.
_value = prop.value()
254 self.
_value = eval(prop.toString(), {}, {})
256 if hasattr(prop,
"value"):
257 self.
_value = prop.value()
259 self.
_value = prop.toString()
261 self.
__doc__ +=
" --- Default value = " + str(self.
_value) +
" --- "
262 if prop.documentation() !=
"none":
274 "Return the underlying property itself"
288 """Python equivalent to the C++ Property interface"""
292 self.__dict__[
"_svcloc"] = gbl.Gaudi.svcLocator()
293 self.__dict__[
"_name"] = name
304 if not getattr(self, ifname):
305 self.retrieveInterface()
306 return getattr(getattr(self, ifname), method)(*args)
310 The method which is used for setting the property from the given value.
311 - In the case of the valid instance it sets the property through IProperty interface
312 - In the case of placeholder the property is added to JobOptionsCatalogue
314 if hasattr(value,
"toStringProperty"):
316 value = str(value.toStringProperty())
317 elif hasattr(value,
"toString"):
318 value = str(value.toString())
319 elif isinstance(value, long):
326 if not gbl.Gaudi.Utils.hasProperty(ip, name):
327 raise AttributeError(
"property %s does not exist" % name)
328 ip.setPropertyRepr(name, value)
330 gbl.GaudiPython.Helpers.setProperty(
331 self._svcloc,
".".join([self._name, name]), value
336 The method which returns the value for the given property
337 - In the case of the valid instance it returns the valid property value through IProperty interface
338 - In the case of placeholder the property value is retrieved from JobOptionsCatalogue
342 if not gbl.Gaudi.Utils.hasProperty(ip, name):
343 raise AttributeError(
"property %s does not exist" % name)
344 prop = ip.getProperty(name)
345 if StringProperty ==
type(prop):
347 elif StringPropertyRef ==
type(prop):
350 return eval(prop.toString(), {}, {})
354 opts = self._svcloc.getOptsSvc()
355 if opts.has(
"{}.{}".
format(self._name, name)):
357 return eval(opts.get(
"{}.{}".
format(self._name, name)), {}, {})
358 raise AttributeError(
"property %s does not exist" % name)
365 props = ip.getProperties()
366 propsFrom = self._name
368 raise NotImplementedError(
"rely on IJobOptionsSvc")
369 props = self._optsvc.getProperties(self._name)
370 propsFrom =
"jobOptionsSvc"
375 except (ValueError, TypeError)
as e:
377 "gaudimodule.iProperty.properties(): %s%s processing property %s.%s = %s"
378 % (e.__class__.__name__, e.args, propsFrom, p.name(), p.value())
390 """Python equivalent to IProperty interface"""
393 iProperty.__init__(self, name, isvc)
397 isvc = Helper.service(self._svcloc, self._name)
399 iService.__init__(self, self._name, isvc)
430 """Python equivalent to IAlgorithm interface"""
433 iProperty.__init__(self, name, ialg)
437 ialg = Helper.algorithm(
441 iAlgorithm.__init__(self, self._name, ialg)
490 """Python equivalent to IAlgTool interface (not completed yet)"""
493 iProperty.__init__(self, name, itool)
494 self.__dict__[
"_itool"] = itool
495 svc = Helper.service(self._svcloc,
"ToolSvc",
True)
496 self.__dict__[
"_toolsvc"] =
iToolSvc(
"ToolSvc", svc)
499 itool = self._toolsvc._retrieve(self._name)
501 iAlgTool.__init__(self, self._name, itool)
514 return self._itool.
name()
524 iService.__init__(self, name, idp)
525 self.__dict__[
"_idp"] =
InterfaceCast(gbl.IDataProviderSvc)(idp)
526 self.__dict__[
"_idm"] =
InterfaceCast(gbl.IDataManagerSvc)(idp)
530 raise AttributeError(
531 "C++ service %s does not exist" % self.__dict__[
"_name"]
533 return Helper.registerObject(self._idp, path, obj)
537 raise AttributeError(
538 "C++ service %s does not exist" % self.__dict__[
"_name"]
540 return Helper.unregisterObject(self._idp, path)
545 return Helper.dataobject(self._idp, path)
552 Get the existing object in TransientStore for the given location
554 - loading of object from persistency is NOT triggered
555 - 'data-on-demand' action is NOT triggered
557 >>> svc = ... ## get the service
558 >>> path = ... ## get the path in Transient Store
559 >>> data = svc.findObject ( path ) ## use the method
563 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
564 return Helper.findobject(self._idp, path)
569 Get object from Transient Store for the given location
572 - path : Location of object in Transient Store
573 - retrieve (bool) True : retrieve versus find
574 - disable on-demand (bool) False : temporary disable 'on-demand' actions
576 >>> svc = ... ## get the service
577 >>> path = ... ## get the path
579 >>> data = svc.getObject ( path , False ) ## find object in Transient Store
581 ## find object in Transient Store
582 # load form tape or use 'on-demand' action for missing objects :
583 >>> data = svc.getObject ( path , True )
585 ## find object in Transient Store
586 # load from tape or for missing objects, disable 'on-demand'-actions
587 >>> data = svc.getObject ( path , True , True )
591 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
592 return Helper.getobject(self._idp, path, *args)
596 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
597 return Helper.dataobject(self._idp, path)
601 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
606 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
610 if node == cppyy.nullptr:
612 ll = gbl.std.vector(
"IRegistry*")()
613 if isinstance(node, str):
615 if self._idm.objectLeaves(node, ll).isSuccess():
618 def dump(self, node=cppyy.nullptr):
619 if node == cppyy.nullptr:
622 node = root.registry()
625 print(node.identifier())
627 for l
in self.
leaves(node):
630 def getList(self, node=cppyy.nullptr, lst=[], rootFID=None):
631 if node == cppyy.nullptr:
634 node = root.registry()
635 rootFID = node.address().
par()
639 Helper.dataobject(self._idp, node.identifier())
641 lst.append(node.identifier())
642 for l
in self.
leaves(node):
643 if l.address()
and l.address().
par() == rootFID:
650 if node == cppyy.nullptr:
653 node = root.registry()
658 Helper.dataobject(self._idp, node.identifier())
660 lst.append(node.identifier())
661 for l
in self.
leaves(node):
670 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
671 return self._idm.
setRoot(name, obj)
675 raise IndexError(
"C++ service %s does not exist" % self.__dict__[
"_name"])
682 self.__dict__[
"_ihs"] =
InterfaceCast(gbl.IHistogramSvc)(ihs)
683 iDataSvc.__init__(self, name, ihs)
686 return Helper.histo1D(self._ihs, path)
689 return Helper.histo2D(self._ihs, path)
692 return Helper.histo3D(self._ihs, path)
695 return Helper.profile1D(self._ihs, path)
698 return Helper.profile2D(self._ihs, path)
702 Retrieve AIDA histogram or AIDA profile histogram by path in Histogram Transient Store
704 >>> histo = svc.retrieve ( 'path/to/my/histogram' )
719 Book the histograms(1D,2D&3D) , see IHistogramSvc::book
721 >>> histo = svc.book( .... )
723 return self._ihs.
book(*args)
727 Book the profile(1D&2D) histograms, see IHistogramSvc::bookProf
729 >>> histo = svc.bookProf( .... )
735 Retrieve the object from Histogram Transient Store (by path)
736 The reference to AIDA histogram is returned (if possible)
738 >>> histo = svc['path/to/my/histogram']
743 return iDataSvc.__getitem__(self, path)
747 Retrieve the histogram from Histogram Transient Store (by path)
748 The reference to AIDA histogram is returned (if possible)
750 >>> histo = svc.getAsAIDA ( 'path/to/my/histogram' )
756 Retrieve the histogram from Histogram Transient Store (by path)
757 The Underlying native ROOT object is returned (if possible)
759 >>> histo = svc.getAsROOT ( 'path/to/my/histogram' )
761 fun = gbl.Gaudi.Utils.Aida2ROOT.aida2root
774 iDataSvc.__init__(self, name, ints)
777 return self._ints.
book(*args)
780 """Defines the mapping between logical names and the output file
782 defineOutput({'LUN1':'MyFile1.root', 'LUN2':'Myfile2.root'}, svc='Gaudi::RootCnvSvc')
784 from .
import Persistency
as prs
786 helper = prs.get(typ)
787 helper.configure(
AppMgr())
788 self.
Output = [helper.formatOutput(files[lun], lun=lun)
for lun
in files]
789 if AppMgr().HistogramPersistency ==
"NONE":
790 AppMgr().HistogramPersistency =
"ROOT"
793 return iDataSvc.__getitem__(self, path)
800 iService.__init__(self, name, its)
803 sol = _gaudi.OutputLevel
806 if name.rfind(
".") == -1:
807 itool = Helper.tool(self._its,
"", name, nullptr,
False)
808 elif name[0:8] ==
"ToolSvc.":
809 itool = Helper.tool(self._its,
"", name[8:], nullptr,
False)
810 elif name.count(
".") > 1:
811 ptool = self.
_retrieve(name[: name.rfind(
".")])
813 self._its,
"", name[name.rfind(
".") + 1 :], ptool,
False
816 prop = _gaudi.property(name[: name.rfind(
".")])
818 self._its,
"", name[name.rfind(
".") + 1 :], prop._ip,
False
827 def create(self, typ, name=None, parent=nullptr, interface=None):
830 itool = Helper.tool(self._its, typ, name, parent,
True)
837 if type(itool)
is iAlgTool:
838 self._its.releaseTool(itool._itool)
849 Helper.service(gbl.Gaudi.svcLocator(),
"EventSelector"),
851 self.__dict__[
"g"] =
AppMgr()
853 def open(self, stream, typ="Gaudi::RootCnvSvc
", **kwargs):
854 from .
import Persistency
as prs
856 helper = prs.get(typ)
857 helper.configure(self.g)
858 self.
Input = helper.formatInput(stream, **kwargs)
873 newobj = object.__new__(cls)
874 cls.
__init__(newobj, *args, **kwargs)
906 self.__dict__[
"_exit_called"] =
False
908 self.__dict__[
"_gaudi_ns"] = Gaudi
910 from GaudiKernel.Proxy.Configurable
import expandvars
916 if dllname
and factname:
917 self.__dict__[
"_appmgr"] = gbl.Gaudi.createApplicationMgr(dllname, factname)
919 self.__dict__[
"_appmgr"] = gbl.Gaudi.createApplicationMgr(dllname)
921 self.__dict__[
"_appmgr"] = gbl.Gaudi.createApplicationMgr()
922 self.__dict__[
"_svcloc"] = gbl.Gaudi.svcLocator()
924 self.__dict__[
"_evtpro"] =
InterfaceCast(gbl.IEventProcessor)(self._appmgr)
925 self.__dict__[
"_svcmgr"] =
InterfaceCast(gbl.ISvcManager)(self._appmgr)
926 self.__dict__[
"pyalgorithms"] = []
927 iService.__init__(self,
"ApplicationMgr", self._appmgr)
929 if self.
FSMState() < Gaudi.StateMachine.CONFIGURED:
936 import GaudiKernel.Proxy.Configurable
938 if hasattr(GaudiKernel.Proxy.Configurable,
"applyConfigurableUsers"):
939 GaudiKernel.Proxy.Configurable.applyConfigurableUsers()
943 appMgr = Configurable.allConfigurables[
"ApplicationMgr"]
944 selfprops =
expandvars(appMgr.getValuedProperties())
947 for p, v
in selfprops.items():
949 for p, v
in selfoptions.items():
952 if outputlevel != -1:
956 ms = self.
service(
"MessageSvc")
957 if "MessageSvc" in Configurable.allConfigurables:
958 msprops = Configurable.allConfigurables[
"MessageSvc"]
959 ms = self.
service(
"MessageSvc")
960 if hasattr(msprops,
"getValuedProperties"):
961 msprops =
expandvars(msprops.getValuedProperties())
962 for p, v
in msprops.items():
964 if outputlevel != -1:
965 ms.OutputLevel = outputlevel
968 c = Configurable.allConfigurables[n]
969 if n
in [
"ApplicationMgr",
"MessageSvc"]:
971 for p, v
in c.getValuedProperties().
items():
974 if hasattr(Configurable,
"PropertyReference")
and isinstance(
975 v, Configurable.PropertyReference
980 if isinstance(v, str):
982 if isinstance(v, long):
984 gbl.GaudiPython.Helpers.setProperty(
985 self._svcloc,
".".join([n, p]), str(v)
987 if hasattr(Configurable,
"_configurationLocked"):
988 Configurable._configurationLocked =
True
993 atexit.register(self.
exit)
999 orig_register = atexit.register
1001 def register(func, *targs, **kargs):
1002 orig_register(func, *targs, **kargs)
1003 if hasattr(func,
"__module__")
and func.__module__ ==
"ROOT":
1004 orig_register(self.
exit)
1008 register.__doc__ = (
1009 orig_register.__doc__
1010 +
"\nNote: version hacked by GaudiPython to work "
1011 +
"around a problem with the ROOT exit handler"
1013 atexit.register = register
1017 if "_svcloc" in self.__dict__:
1018 return self._svcloc.getOptsSvc()
1031 svc = Helper.service(self._svcloc, name)
1038 self._svcmgr.declareSvcType(svcname, svctype)
1041 return Helper.service(self._svcloc, name,
True)
1044 l = self._svcloc.getServices()
1045 return [s.name()
for s
in l]
1048 alg = Helper.algorithm(self._algmgr, name, createIf)
1055 l = self._algmgr.getAlgorithms()
1056 return [a.name()
for a
in l]
1070 if self.
state() == Gaudi.StateMachine.CONFIGURED:
1072 svc = Helper.service(self._svcloc, name)
1076 return self.
datasvc(
"EventDataSvc")
1079 return self.
datasvc(
"DetectorDataSvc")
1082 return self.
datasvc(
"FileRecordDataSvc")
1085 if self.
state() == Gaudi.StateMachine.CONFIGURED:
1087 if not hasattr(self,
"_evtsel"):
1092 svc = Helper.service(self._svcloc, name)
1096 if name
not in self.ExtSvc:
1097 self.ExtSvc += [name]
1099 svc = Helper.service(self._svcloc, name,
True)
1103 if self.
FSMState() == Gaudi.StateMachine.CONFIGURED:
1105 svc = Helper.service(self._svcloc,
"ParticlePropertySvc")
1109 svc = Helper.service(self._svcloc, name,
True)
1116 """Add an Algorithm to the list of Top algorithms. It can be either a instance of
1117 an Algorithm class or it name"""
1118 if type(alg)
is str:
1121 self.pyalgorithms.append(alg)
1127 self.
topAlg += [alg.name()]
1130 """Set the list of Top Algorithms.
1131 It can be an individual of a list of algorithms names or instances"""
1132 if type(algs)
is not list:
1136 if type(alg)
is str:
1139 self.pyalgorithms.append(alg)
1144 names.append(alg.name())
1148 """Remove an Algorithm to the list of Top algorithms. It can be either a instance of
1149 an Algorithm class or it name"""
1151 if type(alg)
is str:
1154 tmp.remove(alg.name())
1155 self.pyalgorithms.remove(alg)
1161 Print the sequence of Algorithms.
1164 def printAlgo(algName, appMgr, prefix=" "):
1165 print(prefix + algName)
1166 alg = appMgr.algorithm(algName.split(
"/")[-1])
1167 prop = alg.properties()
1168 if "Members" in prop:
1169 subs = prop[
"Members"].value()
1171 printAlgo(i.strip(
'"'), appMgr, prefix +
" ")
1174 prefix =
"ApplicationMgr SUCCESS "
1177 +
"****************************** Algorithm Sequence ****************************"
1179 for i
in mp[
"TopAlg"].value():
1180 printAlgo(i, self, prefix)
1183 +
"******************************************************************************"
1188 Simple utility to perform the configuration of Gaudi application.
1189 It reads the set of input job-options files, and set few
1190 additional parameters 'options' through the usage of temporary *.opts file
1192 gaudi.config( files = [ '$GAUSSOPTS/Gauss.opts' ,
1193 '$DECFILESROOT/options/10022_010.0GeV.opts' ] ,
1194 options = [ 'EventSelector.PrintFreq = 5 ' ] )
1196 files = args.get(
"files", [])
1200 raise RuntimeError(
' Unable to read file "' + file +
'" ')
1201 options = args.get(
"options",
None)
1205 tmpfilename = tempfile.mktemp()
1206 tmpfile = open(tmpfilename,
"w")
1207 tmpfile.write(
"#pragma print on \n")
1209 '/// File "' + tmpfilename +
'" generated by GaudiPython \n\n'
1212 if type(options)
is dict:
1218 +
" ; // added by GaudiPython \n"
1221 tmpfile.write(
" \t " + opt +
" ; // added by GaudiPython \n")
1223 '/// End of file "' + tmpfilename +
'" generated by GaudiPython \n\n'
1228 raise RuntimeError(
' Unable to read file "' + tmpfilename +
'" ')
1229 os.remove(tmpfilename)
1237 return self._appmgr.
start()
1243 if self.
FSMState() == Gaudi.StateMachine.CONFIGURED:
1245 if sc.isFailure()
or self.ReturnCode != 0:
1247 if self.
FSMState() == Gaudi.StateMachine.INITIALIZED:
1249 if sc.isFailure()
or self.ReturnCode != 0:
1251 return self._evtpro.executeRun(n)
1260 if self.
FSMState() == Gaudi.StateMachine.CONFIGURED:
1264 if self.
FSMState() == Gaudi.StateMachine.INITIALIZED:
1269 if not hasattr(self,
"_perssvc"):
1270 self.__dict__[
"_perssvc"] = self.
service(
1271 "EventPersistencySvc",
"IAddressCreator"
1273 if not hasattr(self,
"_filecat"):
1274 self.__dict__[
"_filecat"] = self.
service(
1275 "FileCatalog",
"Gaudi::IFileCatalog"
1277 if not hasattr(self,
"_evtmgr"):
1278 self.__dict__[
"_evtmgr"] = self.
service(
"EventDataSvc",
"IDataManagerSvc")
1280 if pfn.find(
"PFN:") == 0:
1284 if not self._filecat.existsFID(fid):
1285 self._filecat.registerPFN(fid, pfn,
"")
1287 if type(events)
is not list:
1291 gadd = gbl.GenericAddress(0x02, 1, fid,
"/Event", 0, evt)
1293 self._perssvc.createAddress(
1294 gadd.svcType(), gadd.clID(), gadd.par(), gadd.ipar(), oadd
1297 self._evtmgr.clearStore()
1298 self._evtmgr.setRoot(
"/Event", oadd)
1303 if not self._exit_called:
1304 self.__dict__[
"_exit_called"] =
True
1305 Gaudi = self._gaudi_ns
1306 if self.
FSMState() == Gaudi.StateMachine.RUNNING:
1307 self._appmgr.
stop().ignore()
1308 if self.
FSMState() == Gaudi.StateMachine.INITIALIZED:
1310 if self.
FSMState() == Gaudi.StateMachine.CONFIGURED:
1321 ntupleSvc = ntuplesvc
1332 tfile = gbl.TFile.Open(pfn)
1334 raise IOError(
"Cannot open ROOT file {0}".
format(pfn))
1335 tree = tfile.Get(
"##Params")
1337 text = tree.db_string
1338 if "NAME=FID" in text:
1339 fid = text[text.rfind(
"VALUE=") + 6 : -1]
1340 nevt = tfile.Get(
"_Event").GetEntries()
1349 """Get all the properties of a component as a Python dictionary.
1350 The component is instantiated using the component library
1353 if name ==
"GaudiCoreSvc":
1354 if Helper.loadDynamicLib(name) != 1:
1355 raise ImportError(
"Error loading component library " + name)
1356 factorylist = gbl.FactoryTable.instance().getEntries()
1358 _ =
AppMgr(outputlevel=7)
1360 _ =
AppMgr(outputlevel=7)
1361 if Helper.loadDynamicLib(name) != 1:
1362 raise ImportError(
"Error loading component library " + name)
1363 factorylist = gbl.FactoryTable.instance().getEntries()
1365 svcloc = gbl.Gaudi.svcLocator()
1366 dummysvc = gbl.Service(
"DummySvc", svcloc)
1367 for factory
in factories:
1374 elif factory.ident() ==
"ApplicationMgr":
1375 ctype =
"ApplicationMgr"
1378 cname = factory.ident().split()[-1]
1379 if ctype
in (
"Algorithm",
"Service",
"AlgTool",
"ApplicationMgr"):
1381 if ctype ==
"AlgTool":
1382 obj = factory.instantiate(dummysvc)
1384 obj = factory.instantiate(svcloc)
1385 except RuntimeError
as text:
1386 print(
"Error instantiating", cname,
" from ", name)
1390 properties[cname] = [ctype, prop.properties()]
1400 for i
in range(factories.size()):
1401 factory = factories.front()
1402 result.append(factory)
1403 factories.pop_front()
1404 for factory
in result:
1405 factories.push_back(factory)
1411 _CallbackStreamBufBase = gbl.GaudiPython.CallbackStreamBuf
1416 _CallbackStreamBufBase.__init__(self, self)
1428 _PyAlgorithm = gbl.GaudiPython.PyAlgorithm
1434 name = self.__class__.__name__
1435 _PyAlgorithm.__init__(self, self, name)
1438 sc = self.
_algmgr.addAlgorithm(self)
1440 raise RuntimeError(
"Unable to add Algorithm")
1443 sc = self.
_algmgr.removeAlgorithm(self)
1468 readline.parse_and_bind(
"tab: complete")