#include <AlgSuperSlice.h>
Inheritance diagram for AlgSuperSlice:

Public Member Functions | |
| AlgSuperSlice () | |
| virtual | ~AlgSuperSlice () |
| virtual void | Trace (const char *c) const |
| virtual void | RunAlg (AlgConfig &ac, CandHandle &ch, CandContext &cx) |
|
|
Definition at line 36 of file AlgSuperSlice.cxx. 00037 {
00038 //
00039 // Purpose: Default constructor.
00040 //
00041 // Arguments: n/a
00042 //
00043 // Return: n/a
00044 //
00045 }
|
|
|
Definition at line 49 of file AlgSuperSlice.cxx. 00050 {
00051 //
00052 // Purpose: Default destructor to delete all static members.
00053 //
00054 // Arguments: n/a
00055 //
00056 // Return: n/a
00057 //
00058 }
|
|
||||||||||||||||
|
Implements AlgBase. Definition at line 62 of file AlgSuperSlice.cxx. References CandHandle::AddDaughterLink(), CandStripHandle::GetCorrBegTime(), CandContext::GetDataIn(), CandHandle::GetDaughterIterator(), and MSG. 00064 {
00065 //
00066 // Purpose: Fills the CandSlice using the CandStrips supplied.
00067 //
00068 // Argument:
00069 // ac in AlgConfig (not used).
00070 // ch in Handle to the CandSlice to fill.
00071 // cx in CandContext containing either CandStripListHandle
00072 // or TObjArray of CandStripHandles.
00073 //
00074 // Return: n/a
00075 //
00076
00077 MSG("BubAlg", Msg::kVerbose)
00078 << "Starting AlgSuperSlice::RunAlg()" << endl;
00079
00080 assert(ch.InheritsFrom("CandSliceHandle"));
00081 CandSliceHandle &csh = dynamic_cast<CandSliceHandle &>(ch);
00082
00083 assert(cx.GetDataIn());
00084
00085 // Check for input type and create iterator.
00086 TIter *chhItr = 0;
00087 if (cx.GetDataIn()->InheritsFrom("TObjArray")) {
00088 const TObjArray *tary =
00089 dynamic_cast<const TObjArray*>(cx.GetDataIn());
00090 chhItr = new TIter(tary);
00091 }
00092 else if (cx.GetDataIn()->InheritsFrom("CandStripListHandle")) {
00093 const CandStripListHandle *chlh =
00094 dynamic_cast<const CandStripListHandle *>(cx.GetDataIn());
00095 chhItr = new TIter(chlh->GetDaughterIterator());
00096 }
00097 else assert(0);
00098
00099 // Loop over all CandStripHandles.
00100 Double_t begtime = 1e7;
00101 Double_t endtime = -1e7;
00102 while (CandStripHandle *chh =
00103 dynamic_cast<CandStripHandle *>((*chhItr)())) {
00104 csh.AddDaughterLink(*chh);
00105 Double_t chhtime = chh->GetCorrBegTime();
00106 if (chhtime < begtime) begtime = chhtime;
00107 if (chhtime > endtime) endtime = chhtime;
00108 }
00109
00110 // Set begin and end times of CandSlice.
00111 // csh.SetCorrBegTime(begtime);
00112 // csh.SetCorrEndTime(endtime);
00113
00114 // Clean-up.
00115 delete chhItr;
00116 chhItr = 0;
00117 }
|
|
|
Reimplemented from AlgBase. Definition at line 121 of file AlgSuperSlice.cxx. References MSG. 00122 {
00123 //
00124 // Purpose: Trace the AlgSuperSlice.
00125 //
00126 // Arguments:
00127 // c in String tag for the trace.
00128 //
00129 // Return: n/a
00130 //
00131
00132 MSG("BubCand", Msg::kDebug)
00133 << "**********Begin AlgSuperSlice::Trace(\"" << c << "\")" << endl
00134 << "**********End AlgSuperSlice::Trace(\"" << c << "\")" << endl;
00135 }
|
1.3.9.1