| # Gaudi Framework, version v25r0 |

Home |  | Generated: Mon Feb 17 2014

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Member Functions | Public Attributes | Static Public Attributes | List of all members
GaudiPython.Bindings.InterfaceCast Class Reference
Inheritance diagram for GaudiPython.Bindings.InterfaceCast:
[legend]
Collaboration diagram for GaudiPython.Bindings.InterfaceCast:
[legend]

## Public Member Functions
def | __init__
def | __call__

## Public Attributes
| type

## Static Public Attributes
| cast __call__

## Detailed Description

    Helper class to obtain the adequate interface from a component
        by using the Gaudi queryInterface() mechanism

Definition at line 78 of file Bindings.py.

## Constructor & Destructor Documentation

def GaudiPython.Bindings.InterfaceCast.__init__ | ( |  | self,
|  |  | t
| ) |  |

Definition at line 81 of file Bindings.py.

81
82 def __init__(self, t ) :
83 if type(t) is str:
84 t = getattr(gbl, t)
self.type = t

## Member Function Documentation

def GaudiPython.Bindings.InterfaceCast.__call__ | ( |  | self,
|  |  | obj
| ) |  |

Definition at line 85 of file Bindings.py.

85
86 def __call__(self, obj) :
87 if obj :
88 ip = makeNullPointer(self.type)
89 try:
90 if obj.queryInterface(self.type.interfaceID(), ip).isSuccess() :
91 return ip
92 else :
93 print "ERROR: queryInterface failed for", obj, "interface:", self.type
94 except Exception, e:
95 print "ERROR: exception", e, "caught when retrieving interface", self.type, "for object", obj
96 import traceback
97 traceback.print_stack()
return None

## Member Data Documentation

GaudiPython.Bindings.InterfaceCast.cast __call__
| static

Definition at line 98 of file Bindings.py.

GaudiPython.Bindings.InterfaceCast.type

Definition at line 84 of file Bindings.py.

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

- /afs/cern.ch/sw/Gaudi/releases/GAUDI/GAUDI_v25r0/GaudiPython/python/GaudiPython/Bindings.py