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

SpillInfoBlock.cxx

Go to the documentation of this file.
00001 #ifndef spillinfoblock_cxx
00002 #define spillinfoblock_cxx
00003 #include <iostream>
00004 #include "Mad/SpillInfoBlock.h"
00005 #include "MessageService/MsgService.h"
00006 #include "Registry/Registry.h"
00007 
00008 ClassImp(SpillInfoBlock)
00009 CVSID("$Id: SpillInfoBlock.cxx,v 1.2 2007/03/01 17:12:22 rhatcher Exp $");
00010 //...........................................
00011 SpillInfoBlock::SpillInfoBlock() : spb_time(0),spb_pot(0),spb_horn(0),
00012                        spb_tgtpos(0),spb_hpos(0),spb_vpos(0),
00013                        spb_magnet(0)
00014 {
00015   MSG("SpillInfoBlock",Msg::kDebug)<<"in SpillInfoBlock()"<<endl;
00016 }
00017 
00018 //...........................................
00019 SpillInfoBlock::SpillInfoBlock(Double_t time, Double_t pot, Double_t horn,
00020                    Double_t tgtpos,Double_t hpos,Double_t vpos,
00021                    Double_t magnet) 
00022 {
00023   MSG("SpillInfoBlock",Msg::kDebug)<<"in SpillInfoBlock(...)"<<endl;
00024  spb_time   = time;
00025  spb_pot    = pot;
00026  spb_horn   = horn;
00027  spb_tgtpos = tgtpos;
00028  spb_hpos   = hpos;
00029  spb_vpos   = vpos;
00030  spb_magnet = magnet;
00031 }
00032 
00033 //...........................................
00034 SpillInfoBlock::~SpillInfoBlock()
00035 {
00036   MSG("SpillInfoBlock",Msg::kDebug)<<"in ~SpillInfoBlock()"<<endl;
00037 }
00038 
00039 //...........................................
00040 SpillInfoBlock SpillInfoBlock::operator=(SpillInfoBlock source)
00041 {
00042    spb_time   = source.GetTime();
00043    spb_pot    = source.GetPot();
00044    spb_horn   = source.GetHorn();
00045    spb_tgtpos = source.GetTgtpos();
00046    spb_hpos   = source.GetHpos();
00047    spb_vpos   = source.GetVpos();
00048    spb_magnet = source.GetMagnet();
00049    
00050   return *this;
00051 }
00052 //...........................................
00053 void SpillInfoBlock::PrintInfo() const
00054 {
00055 
00056   std::cout.precision(25); 
00057   std::cout <<" time = "<<spb_time << std::endl;
00058   std::cout.precision(4); 
00059   std::cout <<" pot = "<< spb_pot
00060            <<" horn = "<<spb_horn <<std::endl;
00061   std::cout<<" tgtpos = "<< spb_tgtpos << " hpos = " << spb_hpos
00062            <<" vpos = "<< spb_vpos << std::endl;
00063   std::cout<<" magnet  = "<< spb_magnet << std::endl;
00064 
00065 }
00066 
00067 //...........................................
00068 void SpillInfoBlock::Zero()
00069 {
00070  spb_time   =-999.;
00071  spb_pot    =-999.; 
00072  spb_horn   =-999.;
00073  spb_tgtpos =-999.;
00074  spb_hpos   =-999.;
00075  spb_vpos   =-999.;
00076  spb_magnet =-999.;
00077 }
00078 #endif

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