ATLAS Offline Software
Public Member Functions | Protected Member Functions | Private Attributes | List of all members
InDetPerfNtupleBranch< branchType > Class Template Reference

This defines a helper class used for writing output ntuples in IDPVM. More...

#include <InDetPerfNtupleBranch.h>

Collaboration diagram for InDetPerfNtupleBranch< branchType >:

Public Member Functions

 InDetPerfNtupleBranch (const std::string &branchName, branchType defaultValue, InDetPerfNtuple &mgr)
 
branchType & operator() ()
 
branchType & get ()
 
void set (const branchType &in)
 
void operator= (const branchType &in)
 
void setDummy ()
 

Protected Member Functions

virtual TBranch * addPayloadAsBranch (TTree *targetTree)
 

Private Attributes

const branchType m_default
 
branchType m_content {m_default}
 

Detailed Description

template<typename branchType>
class InDetPerfNtupleBranch< branchType >

This defines a helper class used for writing output ntuples in IDPVM.

Definition at line 11 of file InDetPerfNtupleBranch.h.

Constructor & Destructor Documentation

◆ InDetPerfNtupleBranch()

template<typename branchType >
InDetPerfNtupleBranch< branchType >::InDetPerfNtupleBranch ( const std::string &  branchName,
branchType  defaultValue,
InDetPerfNtuple mgr 
)
inline

Definition at line 61 of file InDetPerfNtupleBranch.h.

61  :
62  InDetPerfNtupleBranchBase(branchName, mgr),
63  m_default{defaultValue} {
64  }

Member Function Documentation

◆ addPayloadAsBranch()

template<typename branchType >
virtual TBranch* InDetPerfNtupleBranch< branchType >::addPayloadAsBranch ( TTree *  targetTree)
inlineprotectedvirtual

Definition at line 79 of file InDetPerfNtupleBranch.h.

79  {
80  return (targetTree ? targetTree->Branch(getName().c_str(), &m_content) : nullptr);
81  }

◆ get()

template<typename branchType >
branchType& InDetPerfNtupleBranch< branchType >::get ( )
inline

Definition at line 68 of file InDetPerfNtupleBranch.h.

68 { return m_content; }

◆ operator()()

template<typename branchType >
branchType& InDetPerfNtupleBranch< branchType >::operator() ( )
inline

Definition at line 67 of file InDetPerfNtupleBranch.h.

67 { return get(); }

◆ operator=()

template<typename branchType >
void InDetPerfNtupleBranch< branchType >::operator= ( const branchType &  in)
inline

Definition at line 72 of file InDetPerfNtupleBranch.h.

72 { set(in); }

◆ set()

template<typename branchType >
void InDetPerfNtupleBranch< branchType >::set ( const branchType &  in)
inline

Definition at line 71 of file InDetPerfNtupleBranch.h.

71 { m_content=in; }

◆ setDummy()

template<typename branchType >
void InDetPerfNtupleBranch< branchType >::setDummy ( )
inline

Definition at line 75 of file InDetPerfNtupleBranch.h.

75 { set(m_default); }

Member Data Documentation

◆ m_content

template<typename branchType >
branchType InDetPerfNtupleBranch< branchType >::m_content {m_default}
private

Definition at line 85 of file InDetPerfNtupleBranch.h.

◆ m_default

template<typename branchType >
const branchType InDetPerfNtupleBranch< branchType >::m_default
private

Definition at line 84 of file InDetPerfNtupleBranch.h.


The documentation for this class was generated from the following file:
InDetPerfNtupleBranch::get
branchType & get()
Definition: InDetPerfNtupleBranch.h:68
InDetPerfNtupleBranch::m_content
branchType m_content
Definition: InDetPerfNtupleBranch.h:85
InDetPerfNtupleBranch::set
void set(const branchType &in)
Definition: InDetPerfNtupleBranch.h:71
dumpTruth.getName
getName
Definition: dumpTruth.py:34
BchCleanup.mgr
mgr
Definition: BchCleanup.py:294
InDetPerfNtupleBranchBase
Definition: InDetPerfNtupleBranch.h:17
InDetPerfNtupleBranch::m_default
const branchType m_default
Definition: InDetPerfNtupleBranch.h:84