| The Gaudi Framework v28r2-patches (bc4ad17a)

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

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

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__ (self, t)
def | __call__ (self, obj)

## 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 86 of file Bindings.py.

## Constructor & Destructor Documentation

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

Definition at line 89 of file Bindings.py.

89 def __init__(self, t ) :
90 if type(t) is str:
91 t = getattr(gbl, t)
92 self.type = t
GaudiPython.Bindings.InterfaceCast.type
type
Definition: Bindings.py:92
GaudiPython.Bindings.InterfaceCast.__init__
def __init__(self, t)
Definition: Bindings.py:89

## Member Function Documentation

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

Definition at line 93 of file Bindings.py.

93 def __call__(self, obj) :
94 if obj :
95 ip = makeNullPointer(self.type)
96 try:
97 if obj.queryInterface(self.type.interfaceID(), ip).isSuccess() :
98 return ip
99 else :
100 print "ERROR: queryInterface failed for", obj, "interface:", self.type
101 except Exception, e:
102 print "ERROR: exception", e, "caught when retrieving interface", self.type, "for object", obj
103 import traceback
104 traceback.print_stack()
105 return None
GaudiPython.Bindings.makeNullPointer
makeNullPointer
Definition: Bindings.py:79
GaudiPython.Bindings.InterfaceCast.type
type
Definition: Bindings.py:92
GaudiPython.Bindings.InterfaceCast.__call__
def __call__(self, obj)
Definition: Bindings.py:93

## Member Data Documentation

GaudiPython.Bindings.InterfaceCast.cast = __call__
| static

Definition at line 106 of file Bindings.py.

GaudiPython.Bindings.InterfaceCast.type

Definition at line 92 of file Bindings.py.

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

- GaudiPython/python/GaudiPython/Bindings.py