ATLAS Offline Software
Loading...
Searching...
No Matches
TileCellCont.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef TILECELLCONT_H
6#define TILECELLCONT_H
7
9
10#include <map>
11#include <vector>
12
14class TileHid2RESrcID;
15
16
23
24class TileCellCont : public std::vector<TileCellCollection*>
25{
26
27 public:
28
30
32 TileCellCont( ) ;
33
35 const std::vector<TileCellCollection*>::const_iterator find(const unsigned int& id) const ;
36 unsigned int find_rod(const unsigned int& id) const ;
37
39 virtual ~TileCellCont() { }
40
47 const std::vector<int>& Rw2CellMap ( int section ) {
48 return m_Rw2Cell[section];
49 }
51 { return m_MBTS; }
53 { return m_MBTS; }
54 std::map<unsigned int, unsigned int>& MBTS_map ( void )
55 { return m_mapMBTS; }
56 const std::vector<unsigned int>* MBTS_RODs()
57 { return &m_mbts_rods; }
58 const std::vector<unsigned int>* MBTS_IDs()
59 { return &m_mbts_IDs; }
60 int MBTS_channel ( void ) { return m_MBTS_channel; }
61
62 StatusCode initialize( void ) ;
63 StatusCode finalize( void ) ;
65 { m_src = p; }
66
68 { return m_src; }
69
70 void eventNumber ( const unsigned int eN) { m_event=eN; };
71 unsigned int eventNumber ( ) const { return m_event; } ;
72 bool cached( const unsigned int&rodid ){
73 if ( m_eventNumber[rodid] != m_event ) { // Decoding a new event
74 // Keep track of last decoded number
75 m_eventNumber[rodid] = m_event;
76 return false;
77 } else return true;
78 }
79 const std::vector<int>& Rw2PmtMap ( int section ) {
80 return m_Rw2Pmt[section];
81 }
82
83private:
84
86 // One needs to keep track of Rw2Cell
87 std::vector<int> m_Rw2Cell[4];
88 // One needs to keep track of Rw2Pmt
89 std::vector<int> m_Rw2Pmt[4];
91 std::vector<unsigned int> m_eventNumber;
93 unsigned int m_event;
94 // No Region Selector for MBTS
95 std::vector<unsigned int> m_mbts_rods;
96 std::vector<unsigned int> m_mbts_IDs;
98 std::map<unsigned int, unsigned int> m_mapMBTS;
102
103};
104
105#endif
106
void section(const std::string &sec)
StatusCode initialize(void)
const std::vector< int > & Rw2PmtMap(int section)
std::vector< unsigned int > m_mbts_IDs
TileCellCollection IDENTIFIABLE
int MBTS_channel(void)
const TileHid2RESrcID * m_src
map Hash ID to ROD
std::vector< int > m_Rw2Cell[4]
void eventNumber(const unsigned int eN)
unsigned int find_rod(const unsigned int &id) const
unsigned int m_event
this event number
std::vector< unsigned int > m_mbts_rods
const std::vector< int > & Rw2CellMap(int section)
TileRodIdHash m_hash
const std::vector< TileCellCollection * >::const_iterator find(const unsigned int &id) const
Finds a collection.
TileCellCollection * MBTS_collection(void)
const TileCellCollection * MBTS_collection(void) const
bool cached(const unsigned int &rodid)
TileCellCollection * m_MBTS
void setHashIdToROD(const TileHid2RESrcID *p)
unsigned int eventNumber() const
std::vector< int > m_Rw2Pmt[4]
StatusCode finalize(void)
TileCellCont()
constructor
virtual ~TileCellCont()
destructor
std::vector< unsigned int > m_eventNumber
eventNumber of a given Collection
const TileHid2RESrcID * getHashIdToROD() const
const std::vector< unsigned int > * MBTS_IDs()
std::map< unsigned int, unsigned int > m_mapMBTS
const std::vector< unsigned int > * MBTS_RODs()
std::map< unsigned int, unsigned int > & MBTS_map(void)
This class provides conversion between fragment ID and RESrcID.
Table to convert ROB ID to fragment hash.