NuMadAnalysis Class Reference

#include <NuMadAnalysis.h>

Inheritance diagram for NuMadAnalysis:

MadQuantities MadBase List of all members.

Public Member Functions

 NuMadAnalysis ()
 ~NuMadAnalysis ()
void SetEntry (const NtpStRecord *strecord)

Detailed Description

Definition at line 13 of file NuMadAnalysis.h.


Constructor & Destructor Documentation

NuMadAnalysis::NuMadAnalysis (  ) 

Definition at line 24 of file NuMadAnalysis.cxx.

References MadBase::Clear(), MadBase::emrecord, MadBase::fCurRun, MadBase::isEM, MadBase::isMC, MadBase::isST, MadBase::isTH, Msg::kInfo, MadBase::lastEntry, MadBase::mcrecord, MSG, MadBase::Nentries, MadBase::record, MadBase::strecord, MadBase::threcord, and MadBase::whichSource.

00024                              : MadQuantities()
00025 {
00026   MSG("NuMadAnalysis",Msg::kInfo)
00027     <<"Running NuMadAnalysis Constructor..."<<endl;
00028   
00029   //I don't want to give it a chain...
00030   Bool_t chainSR=false;
00031 
00032   //mad base does this:
00033 
00034   fCurRun = -1;
00035   lastEntry = -1;
00036   if(!chainSR) {
00037     record = 0;
00038     emrecord = 0;
00039     mcrecord = 0;
00040     threcord = 0;
00041     strecord = 0;
00042     Clear();
00043     whichSource = -1;
00044     isMC = true;
00045     isTH = true;
00046     isEM = true;
00047     isST = false;
00048     Nentries = -1;
00049     fCurRun = -1;
00050     return;
00051   }
00052 
00053 }

NuMadAnalysis::~NuMadAnalysis (  ) 

Definition at line 57 of file NuMadAnalysis.cxx.

References Msg::kDebug, and MSG.

00058 {
00059   MSG("NuMadAnalysis",Msg::kDebug)
00060     <<"Running NuMadAnalysis Destructor..."<<endl;
00061   
00062 
00063   MSG("NuMadAnalysis",Msg::kDebug)
00064     <<"Finished NuMadAnalysis Destructor"<<endl;
00065 }


Member Function Documentation

void NuMadAnalysis::SetEntry ( const NtpStRecord strecord  ) 

Definition at line 69 of file NuMadAnalysis.cxx.

References NtpStRecord::detstatus, MadBase::detStatus, NtpStRecord::dmxstatus, MadBase::dmxStatus, MadBase::eventSummary, NtpStRecord::evthdr, MadBase::fCurRun, RecRecordImp< T >::GetHeader(), RecDataHeader::GetRun(), MadBase::isMC, MadBase::isST, MadBase::isTH, Msg::kVerbose, MadBase::LoadCluster(), MadBase::LoadEvent(), MadBase::LoadShieldStrip(), MadBase::LoadShower(), MadBase::LoadSlice(), MadBase::LoadTrack(), NtpStRecord::mchdr, MadBase::mcHeader, MSG, NtpMCSummary::nmc, MadBase::ntpHeader, MadBase::shieldSummary, MadBase::strecord, NtpStRecord::thstp, and NtpStRecord::vetohdr.

Referenced by NuAnalysis::ChargeSignCut(), NuAnalysis::Efficiencies(), NuAnalysis::EnergySpect(), NuPIDInterface::GetDpID(), NuAnalysis::N_1(), and NuAnalysis::NuMuBarAppearance().

00070 {
00071   MSG("NuMadAnalysis",Msg::kVerbose)
00072     <<"SetEntry..."<<endl;
00073 
00078 
00079   //have to mess about const_casting everything because the 
00080   //base class members aren't const for some reason
00081 
00082   //set the data member
00083   strecord=const_cast<NtpStRecord*>(ntp);
00084   isST=true;
00085 
00086   //strecord=const_cast<NtpStRecord*>(strecord);
00087 
00088   //set other things:
00089   if(isST){
00090     ntpHeader=&(strecord->GetHeader());
00091     mcHeader=const_cast<NtpMCSummary*>(&(strecord->mchdr));
00092     shieldSummary=const_cast<NtpSRShieldSummary*>(&(strecord->vetohdr));
00093     eventSummary=const_cast<NtpSREventSummary*>( &(strecord->evthdr));
00094     dmxStatus=const_cast<NtpSRDmxStatus*>(&(strecord->dmxstatus));
00095     detStatus=const_cast<NtpSRDetStatus*>(&(strecord->detstatus));
00096     if(mcHeader->nmc==0) {
00097       isMC = false; isTH = false;
00098     }
00099     else {
00100       isMC = true;
00101       TClonesArray &array = *(strecord->thstp);
00102       if(array.GetEntries()>0) isTH = true;      
00103     }
00104   }
00105   fCurRun = ntpHeader->GetRun();
00106 
00107   LoadSlice(0);  
00108   LoadEvent(0);
00109   LoadTrack(0);
00110   LoadCluster(0);
00111   LoadShower(0);
00112   LoadShieldStrip(0);
00113   
00114   MSG("NuMadAnalysis",Msg::kVerbose)
00115     <<"SetEntry... done!"<<endl;
00116 }


The documentation for this class was generated from the following files:
Generated on Mon Nov 10 00:56:00 2014 for loon by  doxygen 1.4.7