![]() |
ATLAS Offline Software
|
A Python wrapper around xAOD::RPyEvent. More...
Public Member Functions | |
| def | __init__ (self) |
| Constructor for the class. More... | |
| def | __getitem__ (self, key) |
| Convenient shorthand for retrieving an object. More... | |
| def | contains (self, key, type) |
| Convenient version of the base class's contains function. More... | |
| def | transientContains (self, key, type) |
| Convenient version of the base class's transientContains function. More... | |
A Python wrapper around xAOD::RPyEvent.
In order to make the semi-templated functions of xAOD::RPyEvent more convenient to use from PyROOT, the user is supposed to use an instance of this class, and not ROOT.xAOD.RPyEvent directly.
Definition at line 15 of file RPyEvent.py.
| def python.RPyEvent.RPyEvent.__init__ | ( | self | ) |
| def python.RPyEvent.RPyEvent.__getitem__ | ( | self, | |
| key | |||
| ) |
Convenient shorthand for retrieving an object.
Definition at line 25 of file RPyEvent.py.
| def python.RPyEvent.RPyEvent.contains | ( | self, | |
| key, | |||
| type | |||
| ) |
Convenient version of the base class's contains function.
This function allows the user to, instead of figuring out the exact type name of some C++ type, to rather write code like:
if event.contains( "Electrons", ROOT.xAOD.ElectronContainer_v1 ):
| key | The string key of the object to check for |
| type | The type of the object we are looking for |
True if the object is available in the event, False if it's not Definition at line 42 of file RPyEvent.py.
| def python.RPyEvent.RPyEvent.transientContains | ( | self, | |
| key, | |||
| type | |||
| ) |
Convenient version of the base class's transientContains function.
This function allows the used to, instead of figuring out the exact type name of some C++ type, to rather write code like:
if event.transientContains( "MyElectrons",
ROOT.xAOD.ElectronContainer_v1 ):
| key | The string key of the object to check for |
| type | The type of the object we are looking for |
True if the object is available in the event in a modifiable form, False if it's not Definition at line 66 of file RPyEvent.py.
1.8.18