CMS 3D CMS Logo

Public Types | Public Member Functions | Private Attributes

CSCWireHit Class Reference

#include <CSCWireHit.h>

List of all members.

Public Types

typedef std::vector< int > ChannelContainer

Public Member Functions

CSCWireHitclone () const
 CSCWireHit base class interface.
CSCDetId cscDetId () const
 Position of the wire hit in CSC.
 CSCWireHit (const CSCDetId &id, const float &wHitPos, ChannelContainer &wgroups, const int &tmax, const short int &deadWG, const std::vector< int > &timeBinsOn)
 CSCWireHit ()
short int deadWG () const
 a dead WG in the cluster?
void print () const
 Print content of the wirehit.
std::vector< int > timeBinsOn () const
 Vector of time bins ON for central wire digi, lower of center pair if even number.
int tmax () const
 The timing for the wire hit.
ChannelContainer wgroups () const
 The wire groups used for forming the cluster.
ChannelContainer wgroupsBX () const
 The BX number.
ChannelContainer wgroupsBXandWire () const
 The BX + wire group number.
float wHitPos () const
 The wire hit position expressed in terms of wire #.
 ~CSCWireHit ()

Private Attributes

short int theDeadWG
CSCDetId theDetId
std::vector< int > theTimeBinsOn
ChannelContainer theWgroups
ChannelContainer theWgroupsHighBits
 BX and wire group number combined.
ChannelContainer theWgroupsLowBits
 to extract BX
float theWireHitPosition
int theWireHitTmax
 to extract the wire group number

Detailed Description

Definition at line 17 of file CSCWireHit.h.


Member Typedef Documentation

typedef std::vector<int> CSCWireHit::ChannelContainer

Definition at line 22 of file CSCWireHit.h.


Constructor & Destructor Documentation

CSCWireHit::CSCWireHit ( )

Definition at line 4 of file CSCWireHit.cc.

References i, theWgroups, theWgroupsHighBits, and theWgroupsLowBits.

Referenced by clone().

                       :
  theDetId(),
  theWireHitPosition(),
  theWgroups(),
  theWireHitTmax(),
  theDeadWG(),
  theTimeBinsOn(0)
{
theWgroupsHighBits.clear();
for(int i=0; i<(int)theWgroups.size(); i++)
   theWgroupsHighBits.push_back((theWgroups[i] >> 16) & 0x0000FFFF);
theWgroupsLowBits.clear();
for(int i=0; i<(int)theWgroups.size(); i++)
   theWgroupsLowBits.push_back(theWgroups[i] & 0x0000FFFF);
}
CSCWireHit::CSCWireHit ( const CSCDetId id,
const float &  wHitPos,
ChannelContainer wgroups,
const int &  tmax,
const short int &  deadWG,
const std::vector< int > &  timeBinsOn 
)

Definition at line 20 of file CSCWireHit.cc.

References i, theWgroups, theWgroupsHighBits, and theWgroupsLowBits.

                                                            :
  theDetId( id ), 
  theWireHitPosition( wHitPos ),
  theWgroups( wgroups ),
  theWireHitTmax ( tmax ),
  theDeadWG ( deadWG ),
  theTimeBinsOn( timeBinsOn )
{
theWgroupsHighBits.clear();
for(int i=0; i<(int)theWgroups.size(); i++)
   theWgroupsHighBits.push_back((theWgroups[i] >> 16) & 0x0000FFFF);
theWgroupsLowBits.clear();
for(int i=0; i<(int)theWgroups.size(); i++)
   theWgroupsLowBits.push_back(theWgroups[i] & 0x0000FFFF);
}
CSCWireHit::~CSCWireHit ( )

Definition at line 41 of file CSCWireHit.cc.

{}

Member Function Documentation

CSCWireHit* CSCWireHit::clone ( void  ) const [inline]

CSCWireHit base class interface.

Definition at line 31 of file CSCWireHit.h.

References CSCWireHit().

{ return new CSCWireHit( *this ); }
CSCDetId CSCWireHit::cscDetId ( ) const [inline]

Position of the wire hit in CSC.

Definition at line 34 of file CSCWireHit.h.

References theDetId.

Referenced by print().

{ return theDetId; }
short int CSCWireHit::deadWG ( ) const [inline]

a dead WG in the cluster?

Definition at line 53 of file CSCWireHit.h.

References theDeadWG.

Referenced by CSCMake2DRecHit::hitFromStripAndWire(), and print().

{return theDeadWG; };
void CSCWireHit::print ( void  ) const

Print content of the wirehit.

Debug.

Definition at line 45 of file CSCWireHit.cc.

References gather_cfg::cout, cscDetId(), deadWG(), i, timeBinsOn(), tmax(), wgroups(), wgroupsBX(), wgroupsBXandWire(), and wHitPos().

                        {
   std::cout << " CSCWireHit in CSC Detector: " << std::dec << cscDetId() << std::endl;
   std::cout << " wHitPos: " << wHitPos() << std::endl;
   std::cout << " BX + WireGroups combined: ";
   for (int i=0; i<(int)wgroupsBXandWire().size(); i++) {std::cout //std::dec << wgroups()[i] 
        << "HEX: " << std::hex << wgroupsBXandWire()[i] << std::hex << " ";
   }
   std::cout << std::endl;
   std::cout << " WireGroups: ";
   for (int i=0; i<(int)wgroups().size(); i++) {std::cout << std::dec << wgroups()[i] 
       << " (" << "HEX: " << std::hex << wgroups()[i] << ")" << " ";
   }
   std::cout << " BX#: ";
   for (int i=0; i<(int)wgroupsBX().size(); i++) {std::cout << std::dec << wgroupsBX()[i] 
       << " (" << "HEX: " << std::hex << wgroupsBX()[i] << ")" << " ";
   }
   
   std::cout << std::endl;
   std::cout << " TMAX: " << std::dec << tmax() << std::endl;
   std::cout << " Dead WG: " << deadWG() << std::endl;
   std::cout << " Time bins on: ";
   for (int i=0; i<(int) timeBinsOn().size(); i++) std::cout << timeBinsOn()[i] << " ";
   std::cout << std::endl;
}
std::vector<int> CSCWireHit::timeBinsOn ( ) const [inline]

Vector of time bins ON for central wire digi, lower of center pair if even number.

Definition at line 56 of file CSCWireHit.h.

References theTimeBinsOn.

Referenced by CSCMake2DRecHit::hitFromStripAndWire(), and print().

{return theTimeBinsOn; };
int CSCWireHit::tmax ( ) const [inline]

The timing for the wire hit.

Definition at line 50 of file CSCWireHit.h.

References theWireHitTmax.

Referenced by print().

{ return theWireHitTmax; }
ChannelContainer CSCWireHit::wgroups ( ) const [inline]

The wire groups used for forming the cluster.

Definition at line 41 of file CSCWireHit.h.

References theWgroupsLowBits.

Referenced by CSCMake2DRecHit::hitFromStripAndWire(), and print().

{ return theWgroupsLowBits; }
ChannelContainer CSCWireHit::wgroupsBX ( ) const [inline]

The BX number.

Definition at line 44 of file CSCWireHit.h.

References theWgroupsHighBits.

Referenced by print().

{ return theWgroupsHighBits; }
ChannelContainer CSCWireHit::wgroupsBXandWire ( ) const [inline]

The BX + wire group number.

Definition at line 47 of file CSCWireHit.h.

References theWgroups.

Referenced by CSCMake2DRecHit::hitFromStripAndWire(), and print().

{ return theWgroups; }
float CSCWireHit::wHitPos ( ) const [inline]

The wire hit position expressed in terms of wire #.

Definition at line 37 of file CSCWireHit.h.

References theWireHitPosition.

Referenced by print().

{ return theWireHitPosition; }

Member Data Documentation

short int CSCWireHit::theDeadWG [private]

Definition at line 68 of file CSCWireHit.h.

Referenced by deadWG().

Definition at line 62 of file CSCWireHit.h.

Referenced by cscDetId().

std::vector<int> CSCWireHit::theTimeBinsOn [private]

Definition at line 69 of file CSCWireHit.h.

Referenced by timeBinsOn().

Definition at line 64 of file CSCWireHit.h.

Referenced by CSCWireHit(), and wgroupsBXandWire().

BX and wire group number combined.

Definition at line 65 of file CSCWireHit.h.

Referenced by CSCWireHit(), and wgroupsBX().

to extract BX

Definition at line 66 of file CSCWireHit.h.

Referenced by CSCWireHit(), and wgroups().

Definition at line 63 of file CSCWireHit.h.

Referenced by wHitPos().

to extract the wire group number

Definition at line 67 of file CSCWireHit.h.

Referenced by tmax().