PlotAllPeds Class Reference

#include <PlotAllPeds.h>

List of all members.

Public Member Functions

 PlotAllPeds ()
bool Start (VldTimeStamp vts=VldTimeStamp::GetBOT())
bool Next (VldTimeStamp end_of_time=VldTimeStamp::GetEOT())
bool Prev (VldTimeStamp beg_of_time=VldTimeStamp::GetBOT())
void DoAll ()

Private Attributes

PlotAllPedsImpimp

Detailed Description

Definition at line 11 of file PlotAllPeds.h.


Constructor & Destructor Documentation

PlotAllPeds::PlotAllPeds (  ) 

Definition at line 95 of file PlotAllPeds.cxx.

00096     : imp(*(new PlotAllPedsImp))
00097 {
00098 }


Member Function Documentation

void PlotAllPeds::DoAll (  ) 

Definition at line 142 of file PlotAllPeds.cxx.

References Next(), and Start().

00143 {
00144     this->Start();
00145     int nzero = 0;
00146     while (nzero < 3) {
00147         if (this->Next()) nzero = 0;
00148         else ++nzero;
00149 
00150         // Give GUI a chance to update.
00151         while (gClient->HandleInput());
00152     }
00153 }

bool PlotAllPeds::Next ( VldTimeStamp  end_of_time = VldTimeStamp::GetEOT()  ) 

Definition at line 110 of file PlotAllPeds.cxx.

References PlotAllPedsImp::drp, VldRange::GetTimeEnd(), DbiResultPtr< T >::GetValidityRec(), DbiValidityRec::GetVldRange(), imp, DbiResultPtr< T >::NextQuery(), and PlotAllPedsImp::Update().

Referenced by DoAll().

00111 {
00112     int nrows = imp.drp.NextQuery();
00113     if (!nrows) {
00114         const DbiValidityRec* vr = imp.drp.GetValidityRec();
00115         VldTimeStamp vts = vr->GetVldRange().GetTimeEnd();
00116         if (vts >= end_of_time) {
00117             cerr << "Reached end of time\n";
00118             return false;
00119         }
00120         cerr << "In gap, not at EOT: " << vts << endl;
00121         return this->Next(end_of_time);
00122     }
00123     
00124     return imp.Update();
00125 }

bool PlotAllPeds::Prev ( VldTimeStamp  beg_of_time = VldTimeStamp::GetBOT()  ) 

Definition at line 126 of file PlotAllPeds.cxx.

References PlotAllPedsImp::drp, VldRange::GetTimeStart(), DbiResultPtr< T >::GetValidityRec(), DbiValidityRec::GetVldRange(), imp, DbiResultPtr< T >::NextQuery(), and PlotAllPedsImp::Update().

00127 {
00128     int nrows = imp.drp.NextQuery(false);
00129     if (!nrows) {
00130         const DbiValidityRec* vr = imp.drp.GetValidityRec();
00131         VldTimeStamp vts = vr->GetVldRange().GetTimeStart();
00132         if (vts <= beg_of_time) {
00133             cerr << "Reached beginning of time\n";
00134             return false;
00135         }
00136         cerr << "In gap, not at BOT: " << vts << endl;
00137         return this->Prev(beg_of_time);
00138     }
00139     
00140     return imp.Update();
00141 }

bool PlotAllPeds::Start ( VldTimeStamp  vts = VldTimeStamp::GetBOT()  ) 

Definition at line 101 of file PlotAllPeds.cxx.

References det, PlotAllPedsImp::drp, imp, SimFlag::kData, Detector::kNear, DbiResultPtr< T >::NewQuery(), and PlotAllPedsImp::Update().

Referenced by DoAll().

00102 {
00103     Detector::Detector_t det = Detector::kNear;
00104     SimFlag::SimFlag_t   sim = SimFlag::kData;
00105     VldContext vc(det,sim,vts);
00106 
00107     imp.drp.NewQuery(vc,0,true);
00108     return imp.Update();
00109 }


Member Data Documentation

Definition at line 12 of file PlotAllPeds.h.

Referenced by Next(), Prev(), and Start().


The documentation for this class was generated from the following files:

Generated on 22 Nov 2017 for loon by  doxygen 1.6.1