Knot Class Reference

#include <Knot.h>

List of all members.

Public Types

typedef std::map< std::string,
AcnetDevice * > 
DeviceMap
 Return a reference to all existing devices as map from name->device.

Public Member Functions

 Knot (TTree &tree)
 Knot ()
void SetTree (TTree &tree)
 (re)Set the tree after creation
int GetSize ()
 Get the number of entries in the tree.
int GetEntry (int entry)
 Get Entry number "entry". Return <0 on error.
int GetEntryNumber ()
 Get current entry number. <0 if none yet set.
const AcnetDeviceGetDevice (const char *name)
const DeviceMapGetDevices () const

Private Attributes

KnotImpfImp

Detailed Description

Definition at line 16 of file Knot.h.


Member Typedef Documentation

typedef std::map<std::string,AcnetDevice*> Knot::DeviceMap

Return a reference to all existing devices as map from name->device.

Definition at line 40 of file Knot.h.


Constructor & Destructor Documentation

Knot::Knot ( TTree &  tree  ) 

Definition at line 62 of file Knot.cxx.

00062 : fImp(new KnotImp(tree)) {}

Knot::Knot (  ) 

Definition at line 63 of file Knot.cxx.

00063 : fImp(0) {}


Member Function Documentation

const AcnetDevice * Knot::GetDevice ( const char *  name  ) 

Get AcnetDevice of given name. This will point to new data each time GetEntry() is called. Returns 0 if not found.

Definition at line 88 of file Knot.cxx.

References fImp, and KnotImp::GetDevice().

Referenced by book_and_fill(), DeltaT::Fill(), MaxDaeDt::Fill(), Npot::Fill(), ProtonDist::Fill(), fill(), Pedestals::GeneratePeds(), horn_off(), make_plots(), pedmaker(), and tortgt_ok().

00089 {
00090     if (!fImp) return 0;
00091     return fImp->GetDevice(name);
00092 }

const Knot::DeviceMap & Knot::GetDevices (  )  const

Definition at line 94 of file Knot.cxx.

References KnotImp::fDeviceMap, and fImp.

00095 {
00096     return fImp->fDeviceMap;
00097 }

int Knot::GetEntry ( int  entry  ) 

Get Entry number "entry". Return <0 on error.

Definition at line 77 of file Knot.cxx.

References fImp, and KnotImp::GetEntry().

Referenced by DeltaT::Fill(), Pedestals::GeneratePeds(), make_plots(), pedmaker(), and PlotterManager::Spin().

00078 {
00079     if (!fImp) return -1;
00080     return fImp->GetEntry(entry);
00081 }

int Knot::GetEntryNumber (  ) 

Get current entry number. <0 if none yet set.

Definition at line 83 of file Knot.cxx.

References KnotImp::fCurrentEntry, and fImp.

Referenced by DeltaT::Fill(), and ProtonDist::Fill().

00084 {
00085     if (!fImp) return -1;
00086     return fImp->fCurrentEntry;
00087 }

int Knot::GetSize (  ) 

Get the number of entries in the tree.

Definition at line 71 of file Knot.cxx.

References fImp, and KnotImp::fTree.

Referenced by Pedestals::GeneratePeds(), make_plots(), pedmaker(), and PlotterManager::Spin().

00072 {
00073     if (!fImp) return -1;
00074     return fImp->fTree.GetEntries();
00075 }

void Knot::SetTree ( TTree &  tree  ) 

(re)Set the tree after creation

Definition at line 65 of file Knot.cxx.

References fImp.

Referenced by DeltaT::NewFile(), and PlotterManager::Spin().

00066 {
00067     if (fImp) delete fImp; fImp = 0;
00068     fImp = new KnotImp(tree);
00069 }


Member Data Documentation

KnotImp* Knot::fImp [private]

Definition at line 17 of file Knot.h.

Referenced by GetDevice(), GetDevices(), GetEntry(), GetEntryNumber(), GetSize(), and SetTree().


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

Generated on 22 Nov 2017 for loon by  doxygen 1.6.1