CMS 3D CMS Logo

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

#include <L1DataEmulDigi.h>

Public Member Functions

int cid () const
 
void data (unsigned int *d) const
 
L1MonitorDigi data () const
 
bool empty () const
 
L1MonitorDigi emul () const
 
 L1DataEmulDigi ()
 
 L1DataEmulDigi (int sid, int cid, double x1, double x2, double x3, int n)
 
 L1DataEmulDigi (int sid, int cid, double x1, double x2, double x3, int n, unsigned int dw, unsigned int ew, float dr, float er, const L1MonitorDigi &dm, const L1MonitorDigi &em)
 
void rank (float *r) const
 
int reset ()
 
void setCid (int cid)
 
void setData (unsigned int d, unsigned int e)
 
void setDEpair (const L1MonitorDigi &d, const L1MonitorDigi &e)
 
void setLocation (double x1, double x2, double x3)
 
void setRank (float d, float e)
 
void setSid (int sid)
 
void setType (int n)
 
int sid () const
 
int type () const
 
double x1 () const
 
double x2 () const
 
double x3 () const
 
 ~L1DataEmulDigi ()
 

Private Attributes

int m_cid
 
unsigned int m_data [2]
 
L1MonitorDigi m_DEpair [2]
 
double m_location [3]
 
int m_null
 
float m_rank [2]
 
int m_sid
 
int m_type
 

Detailed Description

Definition at line 17 of file L1DataEmulDigi.h.

Constructor & Destructor Documentation

◆ L1DataEmulDigi() [1/3]

L1DataEmulDigi::L1DataEmulDigi ( )

Definition at line 28 of file L1DataEmulDigi.cc.

References reset().

28 { reset(); }

◆ L1DataEmulDigi() [2/3]

L1DataEmulDigi::L1DataEmulDigi ( int  sid,
int  cid,
double  x1,
double  x2,
double  x3,
int  n 
)

Definition at line 30 of file L1DataEmulDigi.cc.

References cid(), m_cid, m_location, m_sid, m_type, dqmiodumpmetadata::n, reset(), sid(), x1(), x2(), and x3().

30  {
31  reset();
32  m_sid = sid;
33  m_cid = cid;
34  m_location[0] = x1;
35  m_location[1] = x2;
36  m_location[2] = x3;
37  m_type = n;
38 }
double x3() const
int cid() const
double x2() const
double x1() const
int sid() const
double m_location[3]

◆ L1DataEmulDigi() [3/3]

L1DataEmulDigi::L1DataEmulDigi ( int  sid,
int  cid,
double  x1,
double  x2,
double  x3,
int  n,
unsigned int  dw,
unsigned int  ew,
float  dr,
float  er,
const L1MonitorDigi dm,
const L1MonitorDigi em 
)

Definition at line 40 of file L1DataEmulDigi.cc.

References cid(), symbols::dm, flavorHistoryFilter_cfi::dr, m_cid, m_data, m_DEpair, m_location, m_rank, m_sid, m_type, dqmiodumpmetadata::n, reset(), sid(), x1(), x2(), and x3().

51  {
52  reset();
53  m_sid = sid;
54  m_cid = cid;
55  m_location[0] = x1;
56  m_location[1] = x2;
57  m_location[2] = x3;
58  m_type = n;
59  m_data[0] = dw;
60  m_data[1] = ew;
61  m_rank[0] = dr;
62  m_rank[1] = er;
63  m_DEpair[0] = dm;
64  m_DEpair[1] = em;
65 }
double x3() const
unsigned int m_data[2]
int cid() const
double x2() const
double x1() const
int sid() const
L1MonitorDigi m_DEpair[2]
double m_location[3]

◆ ~L1DataEmulDigi()

L1DataEmulDigi::~L1DataEmulDigi ( )

Definition at line 67 of file L1DataEmulDigi.cc.

67 {}

Member Function Documentation

◆ cid()

int L1DataEmulDigi::cid ( ) const
inline

Definition at line 57 of file L1DataEmulDigi.h.

References m_cid.

Referenced by L1DataEmulDigi(), operator<<(), and setCid().

57 { return m_cid; }

◆ data() [1/2]

void L1DataEmulDigi::data ( unsigned int *  d) const
inline

Definition at line 62 of file L1DataEmulDigi.h.

References ztail::d, and m_data.

Referenced by operator<<().

62  {
63  d[0] = m_data[0];
64  d[1] = m_data[1];
65  }
unsigned int m_data[2]
d
Definition: ztail.py:151

◆ data() [2/2]

L1MonitorDigi L1DataEmulDigi::data ( ) const
inline

Definition at line 70 of file L1DataEmulDigi.h.

References m_DEpair.

70 { return m_DEpair[0]; }
L1MonitorDigi m_DEpair[2]

◆ empty()

bool L1DataEmulDigi::empty ( ) const

Definition at line 4 of file L1DataEmulDigi.cc.

References mps_fire::i, m_cid, m_location, m_null, m_sid, and heppy_batch::val.

4  {
5  if (m_sid == m_null || m_cid == m_null)
6  return true;
7  bool val = true;
8  for (int i = 0; i < 2; i++)
9  val &= (m_location[i] == m_null);
10  return val;
11 }
double m_location[3]

◆ emul()

L1MonitorDigi L1DataEmulDigi::emul ( ) const
inline

Definition at line 71 of file L1DataEmulDigi.h.

References m_DEpair.

71 { return m_DEpair[1]; }
L1MonitorDigi m_DEpair[2]

◆ rank()

void L1DataEmulDigi::rank ( float *  r) const
inline

Definition at line 66 of file L1DataEmulDigi.h.

References m_rank, and alignCSCRings::r.

Referenced by operator<<().

66  {
67  r[0] = m_rank[0];
68  r[1] = m_rank[1];
69  }

◆ reset()

int L1DataEmulDigi::reset ( void  )

Definition at line 13 of file L1DataEmulDigi.cc.

References spu::def(), ntuplemaker::fill, mps_fire::i, m_cid, m_data, m_DEpair, m_location, m_null, m_rank, m_sid, and m_type.

Referenced by L1TdeGCT::analyze(), L1TDEMON::analyze(), and L1DataEmulDigi().

13  {
14  m_null = -99;
15  m_sid = m_null;
16  m_cid = m_null;
17  for (int i = 0; i < 3; i++)
18  m_location[i] = m_null;
19  m_type = m_null;
20  std::fill(m_data, m_data + sizeof(m_data) / sizeof(m_data[0]), 0);
21  std::fill(m_rank, m_rank + sizeof(m_rank) / sizeof(m_rank[0]), m_null);
23  m_DEpair[0] = def;
24  m_DEpair[1] = def;
25  return m_null;
26 }
int def(FILE *, FILE *, int)
unsigned int m_data[2]
L1MonitorDigi m_DEpair[2]
double m_location[3]

◆ setCid()

void L1DataEmulDigi::setCid ( int  cid)
inline

Definition at line 36 of file L1DataEmulDigi.h.

References cid(), and m_cid.

36 { m_cid = cid; }
int cid() const

◆ setData()

void L1DataEmulDigi::setData ( unsigned int  d,
unsigned int  e 
)
inline

Definition at line 43 of file L1DataEmulDigi.h.

References ztail::d, MillePedeFileConverter_cfg::e, and m_data.

Referenced by DEutils< T >::DEDigi().

43  {
44  m_data[0] = d;
45  m_data[1] = e;
46  }
unsigned int m_data[2]
d
Definition: ztail.py:151

◆ setDEpair()

void L1DataEmulDigi::setDEpair ( const L1MonitorDigi d,
const L1MonitorDigi e 
)
inline

Definition at line 51 of file L1DataEmulDigi.h.

References ztail::d, MillePedeFileConverter_cfg::e, and m_DEpair.

Referenced by DEutils< T >::DEDigi().

51  {
52  m_DEpair[0] = d;
53  m_DEpair[1] = e;
54  }
L1MonitorDigi m_DEpair[2]
d
Definition: ztail.py:151

◆ setLocation()

void L1DataEmulDigi::setLocation ( double  x1,
double  x2,
double  x3 
)
inline

Definition at line 37 of file L1DataEmulDigi.h.

References m_location, x1(), x2(), and x3().

37  {
38  m_location[0] = x1;
39  m_location[1] = x2;
40  m_location[2] = x3;
41  }
double x3() const
double x2() const
double x1() const
double m_location[3]

◆ setRank()

void L1DataEmulDigi::setRank ( float  d,
float  e 
)
inline

Definition at line 47 of file L1DataEmulDigi.h.

References ztail::d, MillePedeFileConverter_cfg::e, and m_rank.

Referenced by DEutils< T >::DEDigi().

47  {
48  m_rank[0] = d;
49  m_rank[1] = e;
50  }
d
Definition: ztail.py:151

◆ setSid()

void L1DataEmulDigi::setSid ( int  sid)
inline

Definition at line 35 of file L1DataEmulDigi.h.

References m_sid, and sid().

35 { m_sid = sid; }
int sid() const

◆ setType()

void L1DataEmulDigi::setType ( int  n)
inline

Definition at line 42 of file L1DataEmulDigi.h.

References m_type, and dqmiodumpmetadata::n.

◆ sid()

int L1DataEmulDigi::sid ( ) const
inline

Definition at line 56 of file L1DataEmulDigi.h.

References m_sid.

Referenced by L1DataEmulDigi(), operator<<(), and setSid().

56 { return m_sid; }

◆ type()

int L1DataEmulDigi::type ( ) const
inline

Definition at line 61 of file L1DataEmulDigi.h.

References m_type.

Referenced by operator<<().

61 { return m_type; }

◆ x1()

double L1DataEmulDigi::x1 ( ) const
inline

◆ x2()

double L1DataEmulDigi::x2 ( ) const
inline

◆ x3()

double L1DataEmulDigi::x3 ( ) const
inline

Definition at line 60 of file L1DataEmulDigi.h.

References m_location.

Referenced by L1DataEmulDigi(), operator<<(), and setLocation().

60 { return m_location[2]; }
double m_location[3]

Member Data Documentation

◆ m_cid

int L1DataEmulDigi::m_cid
private

Definition at line 78 of file L1DataEmulDigi.h.

Referenced by cid(), empty(), L1DataEmulDigi(), reset(), and setCid().

◆ m_data

unsigned int L1DataEmulDigi::m_data[2]
private

Definition at line 81 of file L1DataEmulDigi.h.

Referenced by data(), L1DataEmulDigi(), reset(), and setData().

◆ m_DEpair

L1MonitorDigi L1DataEmulDigi::m_DEpair[2]
private

Definition at line 84 of file L1DataEmulDigi.h.

Referenced by data(), emul(), L1DataEmulDigi(), reset(), and setDEpair().

◆ m_location

double L1DataEmulDigi::m_location[3]
private

Definition at line 79 of file L1DataEmulDigi.h.

Referenced by empty(), L1DataEmulDigi(), reset(), setLocation(), x1(), x2(), and x3().

◆ m_null

int L1DataEmulDigi::m_null
private

Definition at line 83 of file L1DataEmulDigi.h.

Referenced by empty(), and reset().

◆ m_rank

float L1DataEmulDigi::m_rank[2]
private

Definition at line 82 of file L1DataEmulDigi.h.

Referenced by L1DataEmulDigi(), rank(), reset(), and setRank().

◆ m_sid

int L1DataEmulDigi::m_sid
private

Definition at line 77 of file L1DataEmulDigi.h.

Referenced by empty(), L1DataEmulDigi(), reset(), setSid(), and sid().

◆ m_type

int L1DataEmulDigi::m_type
private

Definition at line 80 of file L1DataEmulDigi.h.

Referenced by L1DataEmulDigi(), reset(), setType(), and type().