From 8b338c5b95498cefb119cad888e6f6f96281c0e6 Mon Sep 17 00:00:00 2001 From: Carlo Battilana Date: Tue, 23 Apr 2019 15:42:36 +0200 Subject: [PATCH] Add DataFormat for the Phase2 version of DT trigger primitives in the phi view --- .../interface/L1Phase2MuDTPhContainer.h | 57 +++++++++ .../interface/L1Phase2MuDTPhDigi.h | 83 +++++++++++++ .../src/L1Phase2MuDTPhContainer.cc | 48 ++++++++ .../L1DTTrackFinder/src/L1Phase2MuDTPhDigi.cc | 109 ++++++++++++++++++ DataFormats/L1DTTrackFinder/src/classes.h | 2 + .../L1DTTrackFinder/src/classes_def.xml | 12 ++ 6 files changed, 311 insertions(+) create mode 100644 DataFormats/L1DTTrackFinder/interface/L1Phase2MuDTPhContainer.h create mode 100644 DataFormats/L1DTTrackFinder/interface/L1Phase2MuDTPhDigi.h create mode 100644 DataFormats/L1DTTrackFinder/src/L1Phase2MuDTPhContainer.cc create mode 100644 DataFormats/L1DTTrackFinder/src/L1Phase2MuDTPhDigi.cc diff --git a/DataFormats/L1DTTrackFinder/interface/L1Phase2MuDTPhContainer.h b/DataFormats/L1DTTrackFinder/interface/L1Phase2MuDTPhContainer.h new file mode 100644 index 0000000000000..4c0159cd1f432 --- /dev/null +++ b/DataFormats/L1DTTrackFinder/interface/L1Phase2MuDTPhContainer.h @@ -0,0 +1,57 @@ +//------------------------------------------------- +// +// Class L1Phase2MuDTPhContainer +// +// Description: trigger primtive data for the +// muon barrel Phase2 trigger +// +// +// Author List: Federica Primavera Bologna INFN +// +// +//-------------------------------------------------- +#ifndef L1Phase2MuDTPhContainer_H +#define L1Phase2MuDTPhContainer_H + +//------------------------------------ +// Collaborating Class Declarations -- +//------------------------------------ +#include "DataFormats/L1DTTrackFinder/interface/L1Phase2MuDTPhDigi.h" + +//---------------------- +// Base Class Headers -- +//---------------------- +#include + +//--------------- +// C++ Headers -- +//--------------- + +// --------------------- +// -- Class Interface -- +// --------------------- + + +class L1Phase2MuDTPhContainer { + + public: + + typedef std::vector Segment_Container; + typedef Segment_Container::const_iterator Segment_iterator; + + // Constructor + L1Phase2MuDTPhContainer(); + + void setContainer(const Segment_Container& inputSegments); + + Segment_Container const* getContainer() const; + + + private: + + Segment_Container m_segments; + +}; + +#endif + diff --git a/DataFormats/L1DTTrackFinder/interface/L1Phase2MuDTPhDigi.h b/DataFormats/L1DTTrackFinder/interface/L1Phase2MuDTPhDigi.h new file mode 100644 index 0000000000000..5399b4c2fd090 --- /dev/null +++ b/DataFormats/L1DTTrackFinder/interface/L1Phase2MuDTPhDigi.h @@ -0,0 +1,83 @@ +//------------------------------------------------- +// +// Class L1Phase2MuDTPhDigi +// +// Description: trigger primtive data for the +// muon barrel Phase2 trigger +// +// +// Author List: Federica Primavera Bologna INFN +// +// +//-------------------------------------------------- +#ifndef L1Phase2MuDTPhDigi_H +#define L1Phase2MuDTPhDigi_H + +//------------------------------------ +// Collaborating Class Declarations -- +//------------------------------------ + + +//---------------------- +// Base Class Headers -- +//---------------------- + + +//--------------- +// C++ Headers -- +//--------------- + + +// --------------------- +// -- Class Interface -- +// --------------------- + +class L1Phase2MuDTPhDigi +{ + + public: + + // Constructors + L1Phase2MuDTPhDigi(); + + L1Phase2MuDTPhDigi( int bx, int wh, int sc, int st, int phi, int phib, + int qual, int idx, int t0, int chi2, int rpc=-10); + + // Operations + int bxNum() const; + + int whNum() const; + int scNum() const; + int stNum() const; + + int phi() const; + int phiBend() const; + + int quality() const; + int index() const; + + int t0() const; + int chi2() const; + + int rpcFlag() const; + + + private: + + int m_bx; + int m_wheel; + int m_sector; + int m_station; + int m_phiAngle; + int m_phiBending; + + int m_qualityCode; + int m_index; + + int m_t0; + int m_chi2; + + int m_rpcFlag; +}; + +#endif diff --git a/DataFormats/L1DTTrackFinder/src/L1Phase2MuDTPhContainer.cc b/DataFormats/L1DTTrackFinder/src/L1Phase2MuDTPhContainer.cc new file mode 100644 index 0000000000000..8929758bdb6c9 --- /dev/null +++ b/DataFormats/L1DTTrackFinder/src/L1Phase2MuDTPhContainer.cc @@ -0,0 +1,48 @@ +//------------------------------------------------- +// +// Class L1MuDTChambContainer +// +// Description: trigger primtive data for the +// muon barrel Phase2 trigger +// +// +// Author List: Federica Primavera Bologna INFN +// +// +//-------------------------------------------------- + +//----------------------- +// This Class's Header -- +//----------------------- +#include "DataFormats/L1DTTrackFinder/interface/L1Phase2MuDTPhContainer.h" + +//------------------------------- +// Collaborating Class Headers -- +//------------------------------- + + +//--------------- +// C++ Headers -- +//--------------- + +//------------------- +// Initializations -- +//------------------- + + +//---------------- +// Constructors -- +//---------------- +L1Phase2MuDTPhContainer::L1Phase2MuDTPhContainer() {} + +//-------------- +// Operations -- +//-------------- +void L1Phase2MuDTPhContainer::setContainer(const Segment_Container& inputSegments) { + + m_segments = inputSegments; +} + +L1Phase2MuDTPhContainer::Segment_Container const* L1Phase2MuDTPhContainer::getContainer() const { + return &m_segments; +} diff --git a/DataFormats/L1DTTrackFinder/src/L1Phase2MuDTPhDigi.cc b/DataFormats/L1DTTrackFinder/src/L1Phase2MuDTPhDigi.cc new file mode 100644 index 0000000000000..24fe42d88969f --- /dev/null +++ b/DataFormats/L1DTTrackFinder/src/L1Phase2MuDTPhDigi.cc @@ -0,0 +1,109 @@ +//------------------------------------------------- +// +// Class L1MuDTChambPhDigi +// +// Description: trigger primtive data for the +// muon barrel Phase2 trigger +// +// +// Author List: Federica Primavera Bologna INFN +// +// +//-------------------------------------------------- + +//----------------------- +// This Class's Header -- +//----------------------- +#include "DataFormats/L1DTTrackFinder/interface/L1Phase2MuDTPhDigi.h" + +//------------------------------- +// Collaborating Class Headers -- +//------------------------------- + + +//--------------- +// C++ Headers -- +//--------------- + +//------------------- +// Initializations -- +//------------------- + + +//---------------- +// Constructors -- +//---------------- +L1Phase2MuDTPhDigi::L1Phase2MuDTPhDigi() : + m_bx(-100), m_wheel(0), m_sector(0), m_station(0), m_phiAngle(0), m_phiBending(0), + m_qualityCode(-1), m_index(0), m_t0(0), m_chi2(0), m_rpcFlag(-10) +{ + +} + + +L1Phase2MuDTPhDigi::L1Phase2MuDTPhDigi( int bx, int wh, int sc, int st, int phi, int phib, + int qual, int idx, int t0, int chi2, int rpc) : + m_bx(bx), m_wheel(wh), m_sector(sc), m_station(st), m_phiAngle(phi), m_phiBending(phib), + m_qualityCode(qual), m_index(idx), m_t0(t0), m_chi2(chi2), m_rpcFlag(rpc) +{ + +} + + +//-------------- +// Operations -- +//-------------- +int L1Phase2MuDTPhDigi::bxNum() const +{ + return m_bx; +} + +int L1Phase2MuDTPhDigi::whNum() const +{ + return m_wheel; +} + +int L1Phase2MuDTPhDigi::scNum() const +{ + return m_sector; +} + +int L1Phase2MuDTPhDigi::stNum() const +{ + return m_station; +} + +int L1Phase2MuDTPhDigi::phi() const +{ + return m_phiAngle; +} + +int L1Phase2MuDTPhDigi::phiBend() const +{ + return m_phiBending; +} + +int L1Phase2MuDTPhDigi::quality() const +{ + return m_qualityCode; +} + +int L1Phase2MuDTPhDigi::index() const +{ + return m_index; +} + +int L1Phase2MuDTPhDigi::t0() const +{ + return m_t0; +} + +int L1Phase2MuDTPhDigi::chi2() const +{ + return m_chi2; +} + +int L1Phase2MuDTPhDigi::rpcFlag() const +{ + return m_rpcFlag; +} diff --git a/DataFormats/L1DTTrackFinder/src/classes.h b/DataFormats/L1DTTrackFinder/src/classes.h index 1cf5aae0a238b..196fd55fc21c9 100644 --- a/DataFormats/L1DTTrackFinder/src/classes.h +++ b/DataFormats/L1DTTrackFinder/src/classes.h @@ -4,5 +4,7 @@ #include #include #include +#include +#include #include diff --git a/DataFormats/L1DTTrackFinder/src/classes_def.xml b/DataFormats/L1DTTrackFinder/src/classes_def.xml index da260d7dfbaf8..bff4cdbf2feef 100644 --- a/DataFormats/L1DTTrackFinder/src/classes_def.xml +++ b/DataFormats/L1DTTrackFinder/src/classes_def.xml @@ -13,10 +13,16 @@ + + + + + + @@ -27,8 +33,14 @@ + + + + + +