ATLAS Offline Software
AthenaPoolTestMapDataLink.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
14 #ifndef ATHENAPOOLTESTDATA_ATHENAPOOLTESTMAPDATALINK_H
15 # define ATHENAPOOLTESTDATA_ATHENAPOOLTESTMAPDATALINK_H
16 
24 #include <cassert>
25 #include <iostream>
26 #include <limits> /* numeric_limits */
27 #include <string>
28 
29 class MyDummyClass;
30 
32 public:
33  typedef unsigned int index_type;
34 
36 
39  AthenaPoolTestMapDataLink(const MyDummyClass* p, index_type eventIndex = 0);
41 
43 
44  int barcode() const;
45  index_type eventIndex() const;
47 
48  const MyDummyClass* cptr() const;
49 
51  public:
54 
55  unsigned long barcode() const;
56  unsigned short eventIndex() const;
57 
58  private:
59  unsigned long m_BC;
60  unsigned short m_evtIndex;
61  };
62 private:
63  MyDummyClass* m_particle; /* transient */
65 };
66 
67 
69 
71  m_BC(barcode), m_evtIndex(eventIndex)
72 {
74 }
75 
76 inline unsigned long \
78 {
79  return (m_BC);
80 }
81 
82 inline unsigned short
84 {
85  return (m_evtIndex);
86 }
87 
88 inline
90 
91 inline
93  m_particle(0), m_extBarcode(barCode, eventIndex) {}
94 
95 inline
97  m_particle(0), m_extBarcode(0, eventIndex) {}
98 
99 inline int
101 { return int(m_extBarcode.barcode()); } //FIXME ret type
102 
103 inline const MyDummyClass*
105 {
106  return (m_particle);
107 }
108 
109 
112 { return index_type(m_extBarcode.eventIndex()); }
113 
114 
115 //<<<<<< INLINE PUBLIC FUNCTIONS >>>>>>
116 //<<<<<< INLINE MEMBER FUNCTIONS >>>>>>
117 
118 #endif // ATHENAPOOLTESTDATA_ATHENAPOOLTESTMAPDATALINK_H
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
max
#define max(a, b)
Definition: cfImp.cxx:41
CaloCellPos2Ntuple.int
int
Definition: CaloCellPos2Ntuple.py:24
HepMC::barcode
int barcode(const T *p)
Definition: Barcode.h:16
EventInfoCnvParams::eventIndex
thread_local event_number_t eventIndex
Definition: IEvtIdModifierSvc.h:34