CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Attributes
L1MuDTSecProcMap Class Reference

#include <L1MuDTSecProcMap.h>

Public Types

typedef std::map< L1MuDTSecProcId, std::unique_ptr< L1MuDTSectorProcessor > > SPmap
 
typedef SPmap::iterator SPmap_iter
 

Public Member Functions

SPmap_iter begin ()
 return iterator which points to the first entry of the container More...
 
SPmap_iter end ()
 return iterator which points to the one-past-last entry of the container More...
 
void insert (const L1MuDTSecProcId &, std::unique_ptr< L1MuDTSectorProcessor > sp)
 insert a Sector Processor into the container More...
 
 L1MuDTSecProcMap ()
 constructor More...
 
int size () const
 return number of entries present in the container More...
 
const L1MuDTSectorProcessorsp (const L1MuDTSecProcId &) const
 return pointer to Sector Processor More...
 
 ~L1MuDTSecProcMap ()
 destructor More...
 

Private Attributes

SPmap m_map
 

Detailed Description

Sector Processor container map which contains all sector processors

N. Neumeister CERN EP

Definition at line 39 of file L1MuDTSecProcMap.h.

Member Typedef Documentation

◆ SPmap

typedef std::map<L1MuDTSecProcId, std::unique_ptr<L1MuDTSectorProcessor> > L1MuDTSecProcMap::SPmap

Definition at line 41 of file L1MuDTSecProcMap.h.

◆ SPmap_iter

typedef SPmap::iterator L1MuDTSecProcMap::SPmap_iter

Definition at line 42 of file L1MuDTSecProcMap.h.

Constructor & Destructor Documentation

◆ L1MuDTSecProcMap()

L1MuDTSecProcMap::L1MuDTSecProcMap ( )

constructor

Definition at line 43 of file L1MuDTSecProcMap.cc.

43 : m_map() {}

◆ ~L1MuDTSecProcMap()

L1MuDTSecProcMap::~L1MuDTSecProcMap ( )
default

destructor

Member Function Documentation

◆ begin()

SPmap_iter L1MuDTSecProcMap::begin ( void  )
inline

return iterator which points to the first entry of the container

Definition at line 60 of file L1MuDTSecProcMap.h.

References m_map.

60 { return m_map.begin(); }

◆ end()

SPmap_iter L1MuDTSecProcMap::end ( void  )
inline

return iterator which points to the one-past-last entry of the container

Definition at line 63 of file L1MuDTSecProcMap.h.

References m_map.

63 { return m_map.end(); }

◆ insert()

void L1MuDTSecProcMap::insert ( const L1MuDTSecProcId id,
std::unique_ptr< L1MuDTSectorProcessor sp 
)

insert a Sector Processor into the container

Definition at line 70 of file L1MuDTSecProcMap.cc.

References l1ctLayer2EG_cff::id, m_map, eostools::move(), and sp().

70  {
71  //SPmap::const_iterator it = m_map.find(id);
72  // if ( it != m_map.end() )
73  // cerr << "Error: More than one Sector Processor with same identifier"
74  // << endl;
75  m_map[id] = std::move(sp);
76 }
const L1MuDTSectorProcessor * sp(const L1MuDTSecProcId &) const
return pointer to Sector Processor
def move(src, dest)
Definition: eostools.py:511

◆ size()

int L1MuDTSecProcMap::size ( void  ) const
inline

return number of entries present in the container

Definition at line 57 of file L1MuDTSecProcMap.h.

References m_map.

Referenced by ntupleDataFormat._Collection::__iter__(), and ntupleDataFormat._Collection::__len__().

57 { return m_map.size(); }

◆ sp()

const L1MuDTSectorProcessor * L1MuDTSecProcMap::sp ( const L1MuDTSecProcId id) const

return pointer to Sector Processor

Definition at line 58 of file L1MuDTSecProcMap.cc.

References ALPAKA_ACCELERATOR_NAMESPACE::vertexFinder::it, and m_map.

Referenced by insert().

58  {
59  SPmap::const_iterator it = m_map.find(id);
60  if (it == m_map.end()) {
61  // cerr << "Error: Sector Processor not in the map" << endl;
62  return nullptr;
63  }
64  return (*it).second.get();
65 }

Member Data Documentation

◆ m_map

SPmap L1MuDTSecProcMap::m_map
private

Definition at line 66 of file L1MuDTSecProcMap.h.

Referenced by begin(), end(), insert(), size(), and sp().