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

DbuVaChipSpars.h

Go to the documentation of this file.
00001 // $Id: DbuVaChipSpars.h,v 1.4 2008/03/12 15:01:40 rhatcher Exp $
00002 
00003 #ifndef DBUVACHIPSPARS_H
00004 #define DBUVACHIPSPARS_H
00005 
00007 // DbuVaChipSpars
00008 //
00009 // Package: DatabaseUpdater
00010 //
00011 // Concept:
00012 //
00013 //
00014 // R. Hatcher 2002-04-19
00016 
00017 #include "DatabaseInterface/DbiTableRow.h"
00018 #include "LeakChecker/Lea.h"
00019 
00020 #include "Validity/VldContext.h"
00021 #include "RawData/RawChannelId.h"
00022 #include <iosfwd>
00023 
00024 class DbiValidityRec;
00025 
00026 class DbuVaChipSpars;
00027 std::ostream& operator<<(std::ostream& os, const DbuVaChipSpars& drs);
00028 
00029 class DbuVaChipSpars : public DbiTableRow
00030 {
00031 
00032 public:
00033 
00034 // Constructors and destructors.
00035 
00036    DbuVaChipSpars() :
00037       fRawChannelId() 
00038       { LEA_CTOR; for (int i=0; i<22; ++i) fChanPed[i] = -1; }
00039 
00040    DbuVaChipSpars(const RawChannelId& rcid) :
00041       fRawChannelId(rcid)
00042       { LEA_CTOR; fRawChannelId.SetVaChannel(0);
00043         for (int i=0; i<22; ++i) fChanPed[i] = -1; }
00044 
00045    DbuVaChipSpars(const RawChannelId& rcid, Short_t* chanpeds) :
00046       fRawChannelId(rcid)
00047       { LEA_CTOR; fRawChannelId.SetVaChannel(0);
00048         for (int i=0; i<22; ++i) fChanPed[i] = chanpeds[i]; }
00049 
00050    virtual ~DbuVaChipSpars(){ LEA_DTOR; };
00051 
00052 // State testing member functions
00053 
00054    virtual Int_t GetAggregateNo() const { return fRawChannelId.GetCrate(); }
00055 
00056 //          UInt_t GetIndex(UInt_t defIndex) const;
00057 
00058    virtual DbiTableRow* CreateTableRow() const { return new DbuVaChipSpars; }
00059 
00060 // I/O  member functions
00061 
00062    virtual void Fill(DbiResultSet& rs,
00063                      const DbiValidityRec* vrec);
00064    virtual void Store(DbiOutRowStream& ors,
00065                       const DbiValidityRec* vrec) const;
00066 
00067    static const char* GetTableDescr();
00068 
00069 private:  
00070 
00071 // Constructors and destructors.
00072 
00073    DbuVaChipSpars(const DbuVaChipSpars& from) 
00074      : DbiTableRow() { LEA_CTOR; *this = from; }
00075 
00076 // Data members
00077 
00078 public: // !!!!!!! for now!
00079 
00080    RawChannelId fRawChannelId;
00081    Short_t      fChanPed[22];  // pedestal values for each channel
00082 
00083 ClassDef(DbuVaChipSpars,0)
00084 
00085 };
00086 
00087 #endif  // DBUVACHIPSPARS_H

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