CMS 3D CMS Logo

Public Member Functions | Protected Member Functions

HcalOtherDetId Class Reference

#include <HcalOtherDetId.h>

Inheritance diagram for HcalOtherDetId:
DetId HcalCalibDetId HcalDcsDetId

List of all members.

Public Member Functions

 HcalOtherDetId (const DetId &id)
HcalOtherDetIdoperator= (const DetId &id)
HcalOtherSubdetector subdet () const
 get the category

Protected Member Functions

 HcalOtherDetId ()
 HcalOtherDetId (HcalOtherSubdetector subdet)
 Constructor from signed ieta, iphi plus composite type and composite data.
 HcalOtherDetId (uint32_t rawid)

Detailed Description

Detector id class which serves as base class for other HCAL-related det ids (cascaded from top bit).

Packing:

[31:28] Global det == HCAL [27:25] HCAL subdet == Other [24:20] Other subdet id [19:0] Available for use

Date:
2007/07/31 15:20:09
Revision:
1.2
Author:
J. Mans - Minnesota

Definition at line 24 of file HcalOtherDetId.h.


Constructor & Destructor Documentation

HcalOtherDetId::HcalOtherDetId ( const DetId id)

Constructor from a generic cell id

Definition at line 15 of file HcalOtherDetId.cc.

References DetId::det(), Exception, DetId::Hcal, HcalOther, DetId::id_, DetId::rawId(), and DetId::subdetId().

                                               {
  if (gen.det()!=Hcal || gen.subdetId()!=HcalOther) {
    throw cms::Exception("Invalid DetId") << "Cannot initialize HcalOtherDetId from " << std::hex << gen.rawId() << std::dec;
  }
  id_=gen.rawId();    
}
HcalOtherDetId::HcalOtherDetId ( ) [protected]

Constructor of a null id

Definition at line 4 of file HcalOtherDetId.cc.

                               {
}
HcalOtherDetId::HcalOtherDetId ( uint32_t  rawid) [explicit, protected]

Constructor from a raw value

Definition at line 7 of file HcalOtherDetId.cc.

                                             : DetId(rawid) {
}
HcalOtherDetId::HcalOtherDetId ( HcalOtherSubdetector  subdet) [protected]

Constructor from signed ieta, iphi plus composite type and composite data.

Definition at line 10 of file HcalOtherDetId.cc.

References DetId::id_.

  : DetId(Hcal,HcalOther) {
  id_|= (int(other_type&0x1F)<<20);
}

Member Function Documentation

HcalOtherDetId & HcalOtherDetId::operator= ( const DetId id)

Assignment from a generic cell id

Reimplemented in HcalCalibDetId.

Definition at line 22 of file HcalOtherDetId.cc.

References DetId::det(), Exception, DetId::Hcal, HcalOther, DetId::id_, DetId::rawId(), and DetId::subdetId().

                                                          {
  if (gen.det()!=Hcal || gen.subdetId()!=HcalOther) {
    throw cms::Exception("Invalid DetId") << "Cannot assign HcalOtherDetId from " << std::hex << gen.rawId() << std::dec; 
  }
  id_=gen.rawId();
  return *this;
}
HcalOtherSubdetector HcalOtherDetId::subdet ( ) const [inline]