ATLAS Offline Software
Loading...
Searching...
No Matches
xAOD::Experimental::RAuxFieldManager Class Reference

Manager for auxiliary branches created dynamically. More...

#include <RAuxFieldManager.h>

Inheritance diagram for xAOD::Experimental::RAuxFieldManager:
Collaboration diagram for xAOD::Experimental::RAuxFieldManager:

Public Member Functions

 RAuxFieldManager (std::unique_ptr< THolder > holder, bool isPrimitive=false)
 Constructor getting hold of a possible branch.
 ~RAuxFieldManager ()
 Destructor.
::Bool_t isPrimitive () const
 Accessor to whether the field is a primitive type, e.g. int, float, bool.
virtual::Int_t getEntry (::Int_t getall=0) override
 Function for updating the object in memory if needed.
virtual const void * object () const override
 Function getting a const pointer to the object being handled.
virtual void * object () override
 Function getting a pointer to the object being handled.
virtual void setObject (void *obj) override
 Function replacing the object being handled.
virtual::Bool_t create () override
 Create the object for the current event.
virtual::Bool_t isSet () const override
 Check if the object was set for the current event.
virtual void reset () override
 Reset the object at the end of processing of an event.
const THolderholder () const
 Accessor to the Holder object.
THolderholder ()
 Accessor to the Holder object.

Private Attributes

::Bool_t m_isSet
 Was the object set for the current event?
::Bool_t m_isPrimitive
 Is field of primitive type, e.g. int, float, bool.
std::unique_ptr< THolderm_holder
 Object holding onto an EDM object in memory.

Detailed Description

Manager for auxiliary branches created dynamically.

This manager class is meant to deal with "simple" auxiliary branches in the xAOD files.

Author
Attila Krasznahorkay Attil.nosp@m.a.Kr.nosp@m.aszna.nosp@m.hork.nosp@m.ay@ce.nosp@m.rn.c.nosp@m.h
RD Schaffer R.D.S.nosp@m.chaf.nosp@m.fer@c.nosp@m.ern..nosp@m.ch

Definition at line 32 of file RAuxFieldManager.h.

Constructor & Destructor Documentation

◆ RAuxFieldManager()

xAOD::Experimental::RAuxFieldManager::RAuxFieldManager ( std::unique_ptr< THolder > holder,
bool isPrimitive = false )

Constructor getting hold of a possible branch.

Definition at line 18 of file RAuxFieldManager.cxx.

19 :
20 IObjectManager(std::move(holder)),
21 m_isSet( kTRUE ),
IObjectManager(std::unique_ptr< THolder > holder)
Constructor.
const THolder * holder() const
Accessor to the Holder object.
::Bool_t m_isPrimitive
Is field of primitive type, e.g. int, float, bool.
::Bool_t m_isSet
Was the object set for the current event?
::Bool_t isPrimitive() const
Accessor to whether the field is a primitive type, e.g. int, float, bool.

◆ ~RAuxFieldManager()

xAOD::Experimental::RAuxFieldManager::~RAuxFieldManager ( )
default

Destructor.

Member Function Documentation

◆ create()

Bool_t xAOD::Experimental::RAuxFieldManager::create ( )
overridevirtual

Create the object for the current event.

Implements xAOD::TVirtualManager.

Definition at line 56 of file RAuxFieldManager.cxx.

56 {
57
58 return m_isSet;
59}

◆ getEntry()

Int_t xAOD::Experimental::RAuxFieldManager::getEntry ( ::Int_t getall = 0)
overridevirtual

Function for updating the object in memory if needed.

Implements xAOD::TVirtualManager.

Definition at line 33 of file RAuxFieldManager.cxx.

33 {
34
35 return 0;
36}

◆ holder() [1/2]

THolder * xAOD::Details::IObjectManager::holder ( )
inherited

Accessor to the Holder object.

Definition at line 48 of file IObjectManager.cxx.

48 {
49
50 return m_holder.get();
51}
std::unique_ptr< THolder > m_holder
Object holding onto an EDM object in memory.

◆ holder() [2/2]

const THolder * xAOD::Details::IObjectManager::holder ( ) const
inherited

Accessor to the Holder object.

Definition at line 43 of file IObjectManager.cxx.

43 {
44
45 return m_holder.get();
46}

◆ isPrimitive()

Bool_t xAOD::Experimental::RAuxFieldManager::isPrimitive ( ) const

Accessor to whether the field is a primitive type, e.g. int, float, bool.

Definition at line 27 of file RAuxFieldManager.cxx.

27 {
28
29 return m_isPrimitive;
30}

◆ isSet()

Bool_t xAOD::Experimental::RAuxFieldManager::isSet ( ) const
overridevirtual

Check if the object was set for the current event.

Implements xAOD::TVirtualManager.

Definition at line 61 of file RAuxFieldManager.cxx.

61 {
62
63 return m_isSet;
64}

◆ object() [1/2]

const void * xAOD::Experimental::RAuxFieldManager::object ( ) const
overridevirtual

Function getting a const pointer to the object being handled.

Implements xAOD::TVirtualManager.

Definition at line 38 of file RAuxFieldManager.cxx.

38 {
39
40 return holder()->get();
41}
const void * get() const
Return a typeless const pointer to the held object.
Definition THolder.cxx:216

◆ object() [2/2]

void * xAOD::Experimental::RAuxFieldManager::object ( )
overridevirtual

Function getting a pointer to the object being handled.

Implements xAOD::TVirtualManager.

Definition at line 43 of file RAuxFieldManager.cxx.

43 {
44
45 return holder()->get();
46}

◆ reset()

void xAOD::Experimental::RAuxFieldManager::reset ( )
overridevirtual

Reset the object at the end of processing of an event.

Implements xAOD::TVirtualManager.

Definition at line 66 of file RAuxFieldManager.cxx.

66 {
67
68 m_isSet = kFALSE;
69 return;
70}

◆ setObject()

void xAOD::Experimental::RAuxFieldManager::setObject ( void * obj)
overridevirtual

Function replacing the object being handled.

Implements xAOD::TVirtualManager.

Definition at line 48 of file RAuxFieldManager.cxx.

48 {
49
50 holder()->set(obj);
51 m_isSet = kTRUE;
52 return;
53}
virtual void set(void *obj)
Replace the managed object.
Definition THolder.cxx:231

Member Data Documentation

◆ m_holder

std::unique_ptr<THolder> xAOD::Details::IObjectManager::m_holder
privateinherited

Object holding onto an EDM object in memory.

Definition at line 44 of file IObjectManager.h.

◆ m_isPrimitive

::Bool_t xAOD::Experimental::RAuxFieldManager::m_isPrimitive
private

Is field of primitive type, e.g. int, float, bool.

Definition at line 66 of file RAuxFieldManager.h.

◆ m_isSet

::Bool_t xAOD::Experimental::RAuxFieldManager::m_isSet
private

Was the object set for the current event?

Definition at line 64 of file RAuxFieldManager.h.


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