|
Gaudi Framework, version v21r11 |
| Home | Generated: 30 Sep 2010 |
Public Member Functions | |
| def | __init__ |
| def | __call__ |
Public Attributes | |
| type | |
Static Public Attributes | |
| cast = __call__ | |
Helper class to obtain the adequate interface from a component
by using the Gaudi queryInterface() mechanism Definition at line 65 of file Bindings.py.
| def GaudiPython::Bindings::InterfaceCast::__init__ | ( | self, | ||
| t | ||||
| ) |
Reimplemented in GaudiPython::Bindings::Interface.
Definition at line 68 of file Bindings.py.
00068 : 00069 if type(t) is str : t = PyCintex.makeClass(t) 00070 self.type = t def __call__(self, obj) :
| def GaudiPython::Bindings::InterfaceCast::__call__ | ( | self, | ||
| obj | ||||
| ) |
Definition at line 71 of file Bindings.py.
00071 : 00072 if obj : 00073 ip = PyCintex.libPyROOT.MakeNullPointer(self.type) 00074 try: 00075 if obj.queryInterface(self.type.interfaceID(), ip).isSuccess() : 00076 return ip 00077 else : 00078 print "ERROR: queryInterface failed for", obj, "interface:", self.type 00079 except Exception, e: 00080 print "ERROR: exception", e, "caught when retrieving interface", self.type, "for object", obj 00081 import traceback 00082 traceback.print_stack() 00083 return None cast = __call__
GaudiPython::Bindings::InterfaceCast::cast = __call__ [static] |
Definition at line 84 of file Bindings.py.
Definition at line 70 of file Bindings.py.