ATLAS Offline Software
Loading...
Searching...
No Matches
AthenaPoolTestMapData.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3*/
4
14
15#ifndef ATHENAPOOLTESTDATA_ATHENAPOOLTESTMAPDATA_H
16# define ATHENAPOOLTESTDATA_ATHENAPOOLTESTMAPDATA_H
17
18//<<<<<< INCLUDES >>>>>>
19
21#include <vector>
22
23//<<<<<< CLASS DECLARATIONS >>>>>>
24
31
33{
34
35public:
36 // A particle link, and the energy (charge) which its hits
37 // contribute to the current RDO.
38 typedef std::pair< AthenaPoolTestMapDataLink, float > Deposit;
39
41 AthenaPoolTestMapData (const std::vector< Deposit >& deposits, int simDataWord = 0);
42 virtual ~AthenaPoolTestMapData();
43
44 int word() const; // Get the packed simdata word
45
46 void deposits(std::vector<Deposit>& deposits) const; // Get the Deposits
47 //std::vector< Deposit > getdeposits() const; // for some reason I can't get this to return by reference! It won't compile. EJWM
48
49 const std::vector< Deposit >& getdeposits() const;
50
51private:
52
53 int m_word;
54 // Deposit* m_p_deposits; but use vector meantime, needs more work
55 std::vector<Deposit> m_deposits;
56};
57
58
59//<<<<<< INLINE PUBLIC FUNCTIONS >>>>>>
60//<<<<<< INLINE MEMBER FUNCTIONS >>>>>>
61
63{
64 return m_word & 0x1fffffff;
65}
66
67inline const std::vector< AthenaPoolTestMapData::Deposit >& AthenaPoolTestMapData::getdeposits() const
68{
69 return m_deposits;
70}
71
72inline void AthenaPoolTestMapData::deposits(std::vector< AthenaPoolTestMapData::Deposit>& deposits) const
73{
74 // I really don't understand what the point of this is ... it does EXACTLY the same as the getdeposits() method, just in a different way. EJWM
76 return;
77}
78
79#endif // ATHENAPOOLTESTDATA_ATHENAPOOLTESTMAPDATA_H
void deposits(std::vector< Deposit > &deposits) const
const std::vector< Deposit > & getdeposits() const
std::vector< Deposit > m_deposits
std::pair< AthenaPoolTestMapDataLink, float > Deposit