ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitAna/Validation/src/GenRelValMod.cc
(Generate patch)

Comparing UserCode/MitAna/Validation/src/GenRelValMod.cc (file contents):
Revision 1.6 by loizides, Mon Mar 23 22:15:16 2009 UTC vs.
Revision 1.7 by loizides, Mon Jun 15 15:00:18 2009 UTC

# Line 1 | Line 1
1   // $Id$
2  
3   #include "MitAna/Validation/interface/GenRelValMod.h"
4 + #include "MitAna/DataTree/interface/MCParticleCol.h"
5   #include "MitAna/DataTree/interface/Names.h"
6  
7   using namespace mithep;
# Line 15 | Line 16 | GenRelValMod::GenRelValMod(const char *n
16    fPrint(1),
17    fWrite(0),
18    fParticles(0),
19 <  ofile(0)
19 >  fOFile(0)
20   {
21    // Constructor.
22   }
# Line 30 | Line 31 | void GenRelValMod::SlaveBegin()
31    ReqBranch(fMCPartName,fParticles);
32  
33    if (fWrite) {
34 <    ofile = new std::ofstream(fFileName);
35 <    if (ofile->bad()) {
34 >    fOFile = new std::ofstream(fFileName);
35 >    if (fOFile->bad()) {
36        SendError(kAbortAnalysis, "SlaveBegin", "Cannot open output file.");
37      }
38    }
# Line 75 | Line 76 | void GenRelValMod::Process()
76        std::cout << buf;
77      }
78      if (fWrite)
79 <      *ofile<<buf;
79 >      *fOFile<<buf;
80    }
81   }
82  
# Line 86 | Line 87 | void GenRelValMod::SlaveTerminate()
87    // the text file.
88  
89    if (fWrite) {
90 <    ofile->close();
91 <    delete ofile;
92 <    ofile=0;
90 >    fOFile->close();
91 >    delete fOFile;
92 >    fOFile=0;
93    }
94   }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines