CMS 3D CMS Logo

Public Types | Public Member Functions | Protected Member Functions | Private Attributes

ESHitResponse Class Reference

#include <ESHitResponse.h>

Inheritance diagram for ESHitResponse:
EcalHitResponse

List of all members.

Public Types

typedef CaloTSamples< float, 3 > ESSamples

Public Member Functions

 ESHitResponse (const CaloVSimParameterMap *parameterMap, const CaloVShape *shape)
virtual bool keepBlank () const
virtual EcalSamplesoperator[] (unsigned int i)
virtual const EcalSamplesoperator[] (unsigned int i) const
virtual unsigned int samplesSize () const
virtual ~ESHitResponse ()

Protected Member Functions

virtual unsigned int samplesSizeAll () const
virtual EcalSamplesvSam (unsigned int i)
virtual const EcalSamplesvSamAll (unsigned int i) const
virtual EcalSamplesvSamAll (unsigned int i)

Private Attributes

std::vector< ESSamplesm_vSam

Detailed Description

Definition at line 7 of file ESHitResponse.h.


Member Typedef Documentation

Definition at line 11 of file ESHitResponse.h.


Constructor & Destructor Documentation

ESHitResponse::ESHitResponse ( const CaloVSimParameterMap parameterMap,
const CaloVShape shape 
)

Definition at line 10 of file ESHitResponse.cc.

References DetId::det(), ESDetId::detIdFromDenseIndex(), i, ESDetId::kSizeForDenseIndexing, m_vSam, Parameters::parameters, CaloVSimParameterMap::simParameters(), findQualityFiles::size, and DetId::subdetId().

                                                                           :
   EcalHitResponse( parameterMap , shape )
{
   assert( 0 != parameterMap ) ;
   assert( 0 != shape ) ;
   const ESDetId detId ( ESDetId::detIdFromDenseIndex( 0 ) ) ;
   const CaloSimParameters& parameters ( parameterMap->simParameters( detId ) ) ;

   const unsigned int rSize ( parameters.readoutFrameSize() ) ;
   const unsigned int nPre  ( parameters.binOfMaximum() - 1 ) ;

   const unsigned int size ( ESDetId::kSizeForDenseIndexing ) ;

   m_vSam.reserve( size ) ;

   for( unsigned int i ( 0 ) ; i != size ; ++i )
   {
      m_vSam.emplace_back(
         CaloGenericDetId( detId.det(), detId.subdetId(), i ) ,
                    rSize, nPre ) ;
   }
}
ESHitResponse::~ESHitResponse ( ) [virtual]

Definition at line 34 of file ESHitResponse.cc.

{
}

Member Function Documentation

virtual bool ESHitResponse::keepBlank ( ) const [inline, virtual]

Definition at line 18 of file ESHitResponse.h.

References funct::false.

{ return false ; }
const EcalHitResponse::EcalSamples * ESHitResponse::operator[] ( unsigned int  i) const [virtual]

Implements EcalHitResponse.

Definition at line 51 of file ESHitResponse.cc.

References i, EcalHitResponse::index(), and m_vSam.

{
   return &m_vSam[ index()[ i ] ] ;
}
EcalHitResponse::EcalSamples * ESHitResponse::operator[] ( unsigned int  i) [virtual]

Implements EcalHitResponse.

Definition at line 57 of file ESHitResponse.cc.

References i, EcalHitResponse::index(), and m_vSam.

{
   return &m_vSam[ index()[ i ] ] ;
}
unsigned int ESHitResponse::samplesSize ( ) const [virtual]

Implements EcalHitResponse.

Definition at line 39 of file ESHitResponse.cc.

References EcalHitResponse::index().

{
   return index().size() ;
}
unsigned int ESHitResponse::samplesSizeAll ( ) const [protected, virtual]

Implements EcalHitResponse.

Definition at line 45 of file ESHitResponse.cc.

References ESDetId::kSizeForDenseIndexing.

EcalHitResponse::EcalSamples * ESHitResponse::vSam ( unsigned int  i) [protected, virtual]

Implements EcalHitResponse.

Definition at line 63 of file ESHitResponse.cc.

References i, EcalHitResponse::index(), and m_vSam.

{
   return &m_vSam[ index()[ i ] ] ;
}
const EcalHitResponse::EcalSamples * ESHitResponse::vSamAll ( unsigned int  i) const [protected, virtual]

Implements EcalHitResponse.

Definition at line 75 of file ESHitResponse.cc.

References i, and m_vSam.

{
   return &m_vSam[ i ] ;
}
EcalHitResponse::EcalSamples * ESHitResponse::vSamAll ( unsigned int  i) [protected, virtual]

Implements EcalHitResponse.

Definition at line 69 of file ESHitResponse.cc.

References i, and m_vSam.

{
   return &m_vSam[ i ] ;
}

Member Data Documentation

std::vector<ESSamples> ESHitResponse::m_vSam [private]

Definition at line 38 of file ESHitResponse.h.

Referenced by ESHitResponse(), operator[](), vSam(), and vSamAll().