Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

NtpSRSlice.h

Go to the documentation of this file.
00001 
00002 //
00003 // NtpSRSlice
00004 //
00005 // NtpSRSlice is an ntuple class to hold slice data
00006 //
00007 // Based on Roy Lee's CandEventSR/SliceSRTTree
00009 
00010 #ifndef NTPSRSLICE_H
00011 #define NTPSRSLICE_H
00012 
00013 #include <iosfwd> // ostream fwd decl'
00014 
00015 #include "CandNtupleSR/NtpSRPlane.h"
00016 #include "CandNtupleSR/NtpSRPulseHeight.h"
00017 
00018 class NtpSRSlice;
00019 std::ostream &operator << (std::ostream& os, const NtpSRSlice& slice);
00020 
00021 class NtpSRSlice : public TObject {
00022 
00023  public:
00024   NtpSRSlice() : index(0),ndigit(0),nstpcnt(0),nstrip(0),stp(0) {} // def ctor
00025   NtpSRSlice(Int_t nstripinit); // normal ctor
00026   virtual ~NtpSRSlice() { this -> Clear(); }
00027 
00028   // State testing methods
00029   virtual std::ostream& Print(std::ostream& os) const;
00030   virtual void Print(Option_t* option = "") const; 
00031 
00032   // State changing methods
00033   void AddStripAt(Int_t stripindex,Int_t ind); 
00034   void Clear(Option_t* = "") { ClearStrips(); }
00035   void ClearStrips() { nstrip = 0; if ( stp ) delete [] stp; stp = 0; }
00036  
00037  public:
00038   // Ntuple is treated like a C-struct with public data members and
00039   // rule-breaking field data members not prefaced by "f" and all
00040   // lowercase, by popular demand.
00041 
00042   UShort_t index; // index of this slice in slice array 
00043   Int_t ndigit;   // number of digits in slice
00044   // nstpcnt will represent the number of strips in track even in "slim"
00045   // ntuple output file for which nstrip is set to 0 and the strip
00046   // array stp has been deleted.
00047   Int_t nstpcnt;  // number of strips in slice 
00048   Int_t nstrip;   // number of strips in strip array 
00049   Int_t* stp;     //[nstrip] indices of associated strips in strip array 
00050   NtpSRPulseHeight ph;      // summed digit pulse height
00051   NtpSRPlane  plane;        // range of planes 
00052 
00053   ClassDef(NtpSRSlice,2)
00054 };
00055 #endif // NTPSRSLICE_H

Generated on Mon Feb 15 11:07:07 2010 for loon by  doxygen 1.3.9.1