Geant4 Cross Reference

Cross-Referencing   Geant4
Geant4/analysis/management/src/G4VAnalysisReader.cc

Version: [ ReleaseNotes ] [ 1.0 ] [ 1.1 ] [ 2.0 ] [ 3.0 ] [ 3.1 ] [ 3.2 ] [ 4.0 ] [ 4.0.p1 ] [ 4.0.p2 ] [ 4.1 ] [ 4.1.p1 ] [ 5.0 ] [ 5.0.p1 ] [ 5.1 ] [ 5.1.p1 ] [ 5.2 ] [ 5.2.p1 ] [ 5.2.p2 ] [ 6.0 ] [ 6.0.p1 ] [ 6.1 ] [ 6.2 ] [ 6.2.p1 ] [ 6.2.p2 ] [ 7.0 ] [ 7.0.p1 ] [ 7.1 ] [ 7.1.p1 ] [ 8.0 ] [ 8.0.p1 ] [ 8.1 ] [ 8.1.p1 ] [ 8.1.p2 ] [ 8.2 ] [ 8.2.p1 ] [ 8.3 ] [ 8.3.p1 ] [ 8.3.p2 ] [ 9.0 ] [ 9.0.p1 ] [ 9.0.p2 ] [ 9.1 ] [ 9.1.p1 ] [ 9.1.p2 ] [ 9.1.p3 ] [ 9.2 ] [ 9.2.p1 ] [ 9.2.p2 ] [ 9.2.p3 ] [ 9.2.p4 ] [ 9.3 ] [ 9.3.p1 ] [ 9.3.p2 ] [ 9.4 ] [ 9.4.p1 ] [ 9.4.p2 ] [ 9.4.p3 ] [ 9.4.p4 ] [ 9.5 ] [ 9.5.p1 ] [ 9.5.p2 ] [ 9.6 ] [ 9.6.p1 ] [ 9.6.p2 ] [ 9.6.p3 ] [ 9.6.p4 ] [ 10.0 ] [ 10.0.p1 ] [ 10.0.p2 ] [ 10.0.p3 ] [ 10.0.p4 ] [ 10.1 ] [ 10.1.p1 ] [ 10.1.p2 ] [ 10.1.p3 ] [ 10.2 ] [ 10.2.p1 ] [ 10.2.p2 ] [ 10.2.p3 ] [ 10.3 ] [ 10.3.p1 ] [ 10.3.p2 ] [ 10.3.p3 ] [ 10.4 ] [ 10.4.p1 ] [ 10.4.p2 ] [ 10.4.p3 ] [ 10.5 ] [ 10.5.p1 ] [ 10.6 ] [ 10.6.p1 ] [ 10.6.p2 ] [ 10.6.p3 ] [ 10.7 ] [ 10.7.p1 ] [ 10.7.p2 ] [ 10.7.p3 ] [ 10.7.p4 ] [ 11.0 ] [ 11.0.p1 ] [ 11.0.p2 ] [ 11.0.p3, ] [ 11.0.p4 ] [ 11.1 ] [ 11.1.1 ] [ 11.1.2 ] [ 11.1.3 ] [ 11.2 ] [ 11.2.1 ] [ 11.2.2 ] [ 11.3.0 ]

Diff markup

Differences between /analysis/management/src/G4VAnalysisReader.cc (Version 11.3.0) and /analysis/management/src/G4VAnalysisReader.cc (Version 10.3.p3)


  1 //                                                  1 //
  2 // *******************************************      2 // ********************************************************************
  3 // * License and Disclaimer                         3 // * License and Disclaimer                                           *
  4 // *                                                4 // *                                                                  *
  5 // * The  Geant4 software  is  copyright of th      5 // * The  Geant4 software  is  copyright of the Copyright Holders  of *
  6 // * the Geant4 Collaboration.  It is provided      6 // * the Geant4 Collaboration.  It is provided  under  the terms  and *
  7 // * conditions of the Geant4 Software License      7 // * conditions of the Geant4 Software License,  included in the file *
  8 // * LICENSE and available at  http://cern.ch/      8 // * LICENSE and available at  http://cern.ch/geant4/license .  These *
  9 // * include a list of copyright holders.           9 // * include a list of copyright holders.                             *
 10 // *                                               10 // *                                                                  *
 11 // * Neither the authors of this software syst     11 // * Neither the authors of this software system, nor their employing *
 12 // * institutes,nor the agencies providing fin     12 // * institutes,nor the agencies providing financial support for this *
 13 // * work  make  any representation or  warran     13 // * work  make  any representation or  warranty, express or implied, *
 14 // * regarding  this  software system or assum     14 // * regarding  this  software system or assume any liability for its *
 15 // * use.  Please see the license in the file      15 // * use.  Please see the license in the file  LICENSE  and URL above *
 16 // * for the full disclaimer and the limitatio     16 // * for the full disclaimer and the limitation of liability.         *
 17 // *                                               17 // *                                                                  *
 18 // * This  code  implementation is the result      18 // * This  code  implementation is the result of  the  scientific and *
 19 // * technical work of the GEANT4 collaboratio     19 // * technical work of the GEANT4 collaboration.                      *
 20 // * By using,  copying,  modifying or  distri     20 // * By using,  copying,  modifying or  distributing the software (or *
 21 // * any work based  on the software)  you  ag     21 // * any work based  on the software)  you  agree  to acknowledge its *
 22 // * use  in  resulting  scientific  publicati     22 // * use  in  resulting  scientific  publications,  and indicate your *
 23 // * acceptance of all terms of the Geant4 Sof     23 // * acceptance of all terms of the Geant4 Software license.          *
 24 // *******************************************     24 // ********************************************************************
 25 //                                                 25 //
                                                   >>  26 // $Id: G4VAnalysisReader.cc 70604 2013-06-03 11:27:06Z ihrivnac $
 26                                                    27 
 27 // Author: Ivana Hrivnacova, 09/07/2013  (ivan     28 // Author: Ivana Hrivnacova, 09/07/2013  (ivana@ipno.in2p3.fr)
 28                                                    29 
 29 #include "G4VAnalysisReader.hh"                    30 #include "G4VAnalysisReader.hh"
 30 #include "G4AnalysisUtilities.hh"                  31 #include "G4AnalysisUtilities.hh"
                                                   >>  32 #include "G4BaseFileManager.hh"
 31 #include "G4HnManager.hh"                          33 #include "G4HnManager.hh"
                                                   >>  34 #include "G4VH1Manager.hh"
                                                   >>  35 #include "G4VH2Manager.hh"
                                                   >>  36 #include "G4VH3Manager.hh"
                                                   >>  37 #include "G4VP1Manager.hh"
                                                   >>  38 #include "G4VP2Manager.hh"
 32 #include "G4VRNtupleManager.hh"                    39 #include "G4VRNtupleManager.hh"
 33 #include "G4VRFileManager.hh"                  <<  40 
 34 #include "G4Threading.hh"                      <<  41 #include <iostream>
 35                                                    42 
 36 using namespace G4Analysis;                        43 using namespace G4Analysis;
 37                                                    44 
 38 //____________________________________________     45 //_____________________________________________________________________________
 39 G4VAnalysisReader::G4VAnalysisReader(const G4S <<  46 G4VAnalysisReader::G4VAnalysisReader(const G4String& type, G4bool isMaster)
 40  : fState(type, ! G4Threading::IsWorkerThread( <<  47  : fState(type, isMaster),
                                                   >>  48    fVH1Manager(nullptr),
                                                   >>  49    fVH2Manager(nullptr),
                                                   >>  50    fVH3Manager(nullptr),
                                                   >>  51    fVP1Manager(nullptr),
                                                   >>  52    fVP2Manager(nullptr),
                                                   >>  53    fVNtupleManager(nullptr),
                                                   >>  54    fFileManager(nullptr)
 41 {}                                                 55 {}
 42                                                    56 
 43 //____________________________________________     57 //_____________________________________________________________________________
 44 G4VAnalysisReader::~G4VAnalysisReader() = defa <<  58 G4VAnalysisReader::~G4VAnalysisReader()
                                                   >>  59 {}
 45                                                    60 
 46 //                                             <<  61 // 
 47 // protected methods                               62 // protected methods
 48 //                                                 63 //
 49                                                <<  64     
 50 //____________________________________________     65 //_____________________________________________________________________________
 51 void G4VAnalysisReader::SetH1Manager(G4VTBaseH <<  66 void G4VAnalysisReader::SetH1Manager(G4VH1Manager* h1Manager)
 52 {                                                  67 {
 53   fVH1Manager.reset(h1Manager);                    68   fVH1Manager.reset(h1Manager);
 54 }                                              <<  69 } 
 55                                                    70 
 56 //____________________________________________     71 //_____________________________________________________________________________
 57 void G4VAnalysisReader::SetH2Manager(G4VTBaseH <<  72 void G4VAnalysisReader::SetH2Manager(G4VH2Manager* h2Manager)
 58 {                                                  73 {
 59   fVH2Manager.reset(h2Manager);                    74   fVH2Manager.reset(h2Manager);
 60 }                                              <<  75 }  
 61                                                    76 
 62 //____________________________________________     77 //_____________________________________________________________________________
 63 void G4VAnalysisReader::SetH3Manager(G4VTBaseH <<  78 void G4VAnalysisReader::SetH3Manager(G4VH3Manager* h3Manager)
 64 {                                                  79 {
 65   fVH3Manager.reset(h3Manager);                    80   fVH3Manager.reset(h3Manager);
 66 }                                              <<  81 }  
 67                                                    82 
 68 //____________________________________________     83 //_____________________________________________________________________________
 69 void G4VAnalysisReader::SetP1Manager(G4VTBaseH <<  84 void G4VAnalysisReader::SetP1Manager(G4VP1Manager* p1Manager)
 70 {                                                  85 {
 71   fVP1Manager.reset(p1Manager);                    86   fVP1Manager.reset(p1Manager);
 72 }                                              <<  87 } 
 73                                                    88 
 74 //____________________________________________     89 //_____________________________________________________________________________
 75 void G4VAnalysisReader::SetP2Manager(G4VTBaseH <<  90 void G4VAnalysisReader::SetP2Manager(G4VP2Manager* p2Manager)
 76 {                                                  91 {
 77   fVP2Manager.reset(p2Manager);                    92   fVP2Manager.reset(p2Manager);
 78 }                                              <<  93 }  
 79                                                    94 
 80 //____________________________________________     95 //_____________________________________________________________________________
 81 void G4VAnalysisReader::SetNtupleManager(std:: <<  96 void G4VAnalysisReader::SetNtupleManager(G4VRNtupleManager* ntupleManager)
 82 {                                                  97 {
 83   fVNtupleManager = std::move(ntupleManager);  <<  98   fVNtupleManager.reset(ntupleManager);
 84 }                                              <<  99 }  
 85                                                   100 
 86 //____________________________________________    101 //_____________________________________________________________________________
 87 void G4VAnalysisReader::SetFileManager(std::sh << 102 void G4VAnalysisReader::SetFileManager(G4BaseFileManager* fileManager)
 88 {                                                 103 {
 89   fVFileManager = std::move(fileManager);      << 104   fFileManager.reset(fileManager);
 90 }                                              << 105 }  
 91                                                   106 
 92 //                                             << 107 // 
 93 // public methods                                 108 // public methods
 94 //                                                109 //
 95                                                   110 
 96 //____________________________________________    111 //_____________________________________________________________________________
 97 G4bool G4VAnalysisReader::CloseFiles(G4bool re << 
 98 {                                              << 
 99   return CloseFilesImpl(reset);                << 
100 }                                              << 
101                                                << 
102 //____________________________________________ << 
103 void G4VAnalysisReader::SetFileName(const G4St    112 void G4VAnalysisReader::SetFileName(const G4String& fileName)
104 {                                              << 113 { 
105   fVFileManager->SetFileName(fileName);        << 114   fFileManager->SetFileName(fileName); 
106 }                                                 115 }
107                                                   116 
108 //____________________________________________    117 //_____________________________________________________________________________
109 G4String G4VAnalysisReader::GetFileName() cons << 118 G4String G4VAnalysisReader::GetFileName() const 
110 {                                              << 119 {  
111   return fVFileManager->GetFileName();         << 120   return fFileManager->GetFileName(); 
112 }                                                 121 }
113                                                   122 
114 //____________________________________________    123 //_____________________________________________________________________________
115 G4int G4VAnalysisReader::ReadH1(const G4String << 124 G4int G4VAnalysisReader::ReadH1(const G4String& h1Name, 
116                                 const G4String << 125                                 const G4String& fileName)
117                                 const G4String << 
118 {                                                 126 {
119   if ( fileName != "" ) {                         127   if ( fileName != "" ) {
120     return ReadH1Impl(h1Name, fileName, dirNam << 128     return ReadH1Impl(h1Name, fileName, true);
121   }                                            << 
122   if (fVFileManager->GetFileName() == "") {    << 
123     Warn("Cannot get H1 " + h1Name + ". File n << 
124     return kInvalidId;                         << 
125   }                                               129   }
126   return ReadH1Impl(h1Name, fVFileManager->Get << 130   else {  
127 }                                              << 131     if ( fFileManager->GetFileName() == "" ) {
                                                   >> 132       G4ExceptionDescription description;
                                                   >> 133       description 
                                                   >> 134         << "Cannot get H1. File name has to be set first.";
                                                   >> 135       G4Exception("G4VAnalysisReader::ReadH1()",
                                                   >> 136                   "Analysis_WR011", JustWarning, description);
                                                   >> 137       return kInvalidId;
                                                   >> 138     }           
                                                   >> 139     return ReadH1Impl(h1Name, fFileManager->GetFileName(), false);
                                                   >> 140   }  
                                                   >> 141 }                                      
128                                                   142 
129 //____________________________________________    143 //_____________________________________________________________________________
130 G4int G4VAnalysisReader::ReadH2(const G4String << 144 G4int G4VAnalysisReader::ReadH2(const G4String& h2Name, 
131                                 const G4String << 145                                 const G4String& fileName)
132                                 const G4String << 
133 {                                                 146 {
134   if ( fileName != "" ) {                         147   if ( fileName != "" ) {
135     return ReadH2Impl(h2Name, fileName, dirNam << 148     return ReadH2Impl(h2Name, fileName, true);
136   }                                            << 
137   if (fVFileManager->GetFileName() == "") {    << 
138     Warn("Cannot get H2 " + h2Name + ". File n << 
139     return kInvalidId;                         << 
140   }                                               149   }
141   return ReadH2Impl(h2Name, fVFileManager->Get << 150   else {  
142 }                                              << 151     if ( fFileManager->GetFileName() == "" ) {
                                                   >> 152       G4ExceptionDescription description;
                                                   >> 153       description 
                                                   >> 154         << "Cannot get H2. File name has to be set first.";
                                                   >> 155       G4Exception("G4VAnalysisReader::ReadH2()",
                                                   >> 156                   "Analysis_WR011", JustWarning, description);
                                                   >> 157       return kInvalidId;
                                                   >> 158     }           
                                                   >> 159     return ReadH2Impl(h2Name, fFileManager->GetFileName(), false);
                                                   >> 160   }  
                                                   >> 161 }                                      
143                                                   162 
144 //____________________________________________    163 //_____________________________________________________________________________
145 G4int G4VAnalysisReader::ReadH3(const G4String << 164 G4int G4VAnalysisReader::ReadH3(const G4String& h3Name, 
146                                 const G4String << 165                                 const G4String& fileName)
147                                 const G4String << 
148 {                                                 166 {
149   if ( fileName != "" ) {                         167   if ( fileName != "" ) {
150     return ReadH3Impl(h3Name, fileName, dirNam << 168     return ReadH3Impl(h3Name, fileName, true);
151   }                                            << 
152   if (fVFileManager->GetFileName() == "") {    << 
153     Warn("Cannot get H3 " + h3Name + ". File n << 
154     return kInvalidId;                         << 
155   }                                               169   }
156   return ReadH3Impl(h3Name, fVFileManager->Get << 170   else {  
157 }                                              << 171     if ( fFileManager->GetFileName() == "" ) {
                                                   >> 172       G4ExceptionDescription description;
                                                   >> 173       description 
                                                   >> 174         << "Cannot get H3. File name has to be set first.";
                                                   >> 175       G4Exception("G4VAnalysisReader::ReadH2()",
                                                   >> 176                   "Analysis_WR011", JustWarning, description);
                                                   >> 177       return kInvalidId;
                                                   >> 178     }           
                                                   >> 179     return ReadH3Impl(h3Name, fFileManager->GetFileName(), false);
                                                   >> 180   }  
                                                   >> 181 }                                      
158                                                   182 
159 //____________________________________________    183 //_____________________________________________________________________________
160 G4int G4VAnalysisReader::ReadP1(const G4String << 184 G4int G4VAnalysisReader::ReadP1(const G4String& p1Name, 
161                                 const G4String << 185                                 const G4String& fileName)
162                                 const G4String << 
163 {                                                 186 {
164   if ( fileName != "" ) {                         187   if ( fileName != "" ) {
165     return ReadP1Impl(p1Name, fileName, dirNam << 188     return ReadP1Impl(p1Name, fileName, true);
166   }                                               189   }
167   if (fVFileManager->GetFileName() == "") {    << 190   else {  
168     Warn("Cannot get P1 " + p1Name + ". File n << 191     if ( fFileManager->GetFileName() == "" ) {
169     return kInvalidId;                         << 192       G4ExceptionDescription description;
170   }                                            << 193       description 
171   return ReadP1Impl(p1Name, fVFileManager->Get << 194         << "Cannot get P1. File name has to be set first.";
172 }                                              << 195       G4Exception("G4VAnalysisReader::ReadP1()",
                                                   >> 196                   "Analysis_WR011", JustWarning, description);
                                                   >> 197       return kInvalidId;
                                                   >> 198     }           
                                                   >> 199     return ReadP1Impl(p1Name, fFileManager->GetFileName(), false);
                                                   >> 200   }  
                                                   >> 201 }                                      
173                                                   202 
174 //____________________________________________    203 //_____________________________________________________________________________
175 G4int G4VAnalysisReader::ReadP2(const G4String << 204 G4int G4VAnalysisReader::ReadP2(const G4String& p2Name, 
176                                 const G4String << 205                                 const G4String& fileName)
177                                 const G4String << 
178 {                                                 206 {
179   if ( fileName != "" ) {                         207   if ( fileName != "" ) {
180     return ReadP2Impl(p2Name, fileName, dirNam << 208     return ReadP2Impl(p2Name, fileName, true);
181   }                                               209   }
182   if (fVFileManager->GetFileName() == "") {    << 210   else {  
183     Warn("Cannot get P2 " + p2Name + ". File n << 211     if ( fFileManager->GetFileName() == "" ) {
184     return kInvalidId;                         << 212       G4ExceptionDescription description;
185   }                                            << 213       description 
186   return ReadP2Impl(p2Name, fVFileManager->Get << 214         << "Cannot get P2. File name has to be set first.";
187 }                                              << 215       G4Exception("G4VAnalysisReader::ReadP2()",
188                                                << 216                   "Analysis_WR011", JustWarning, description);
189 //____________________________________________ << 217       return kInvalidId;
190 G4bool G4VAnalysisReader::SetFirstHistoId(G4in << 218     }           
191 {                                              << 219     return ReadP2Impl(p2Name, fFileManager->GetFileName(), false);
192   auto result = true;                          << 220   }  
193                                                << 221 }                                      
194   result &= SetFirstH1Id(firstId);             << 222 
195   result &= SetFirstH2Id(firstId);             << 223 //_____________________________________________________________________________
196   result &= SetFirstH3Id(firstId);             << 224 G4bool G4VAnalysisReader::SetFirstHistoId(G4int firstId) 
197                                                << 225 {
198   return result;                               << 226   G4bool finalResult = true;
199 }                                              << 227 
                                                   >> 228   G4bool result = SetFirstH1Id(firstId);
                                                   >> 229   finalResult = finalResult && result;
                                                   >> 230   
                                                   >> 231   result = SetFirstH2Id(firstId);
                                                   >> 232   finalResult = finalResult && result;
                                                   >> 233 
                                                   >> 234   result = SetFirstH3Id(firstId);
                                                   >> 235   finalResult = finalResult && result;
                                                   >> 236    
                                                   >> 237   return finalResult; 
                                                   >> 238 }  
200                                                   239 
201 //____________________________________________    240 //_____________________________________________________________________________
202 G4bool G4VAnalysisReader::SetFirstH1Id(G4int f << 241 G4bool G4VAnalysisReader::SetFirstH1Id(G4int firstId) 
203 {                                                 242 {
204   return fVH1Manager->GetHnManager()->SetFirst    243   return fVH1Manager->GetHnManager()->SetFirstId(firstId);
205 }                                              << 244 }  
206                                                   245 
207 //____________________________________________    246 //_____________________________________________________________________________
208 G4bool G4VAnalysisReader::SetFirstH2Id(G4int f << 247 G4bool G4VAnalysisReader::SetFirstH2Id(G4int firstId) 
209 {                                                 248 {
210   return fVH2Manager->GetHnManager()->SetFirst    249   return fVH2Manager->GetHnManager()->SetFirstId(firstId);
211 }                                              << 250 }  
212                                                   251 
213 //____________________________________________    252 //_____________________________________________________________________________
214 G4bool G4VAnalysisReader::SetFirstH3Id(G4int f << 253 G4bool G4VAnalysisReader::SetFirstH3Id(G4int firstId) 
215 {                                                 254 {
216   return fVH3Manager->GetHnManager()->SetFirst    255   return fVH3Manager->GetHnManager()->SetFirstId(firstId);
217 }                                              << 256 }  
218                                                   257 
219 //____________________________________________    258 //_____________________________________________________________________________
220 G4bool G4VAnalysisReader::SetFirstProfileId(G4 << 259 G4bool G4VAnalysisReader::SetFirstProfileId(G4int firstId) 
221 {                                                 260 {
222   auto result = true;                          << 261   G4bool finalResult = true;
223                                                   262 
224   result &= SetFirstP1Id(firstId);             << 263   G4bool result = SetFirstP1Id(firstId);
225   result &= SetFirstP2Id(firstId);             << 264   finalResult = finalResult && result;
                                                   >> 265   
                                                   >> 266   result = SetFirstP2Id(firstId);
                                                   >> 267   finalResult = finalResult && result;
226                                                   268 
227   return result;                               << 269   return finalResult; 
228 }                                              << 270 }  
229                                                   271 
230 //____________________________________________    272 //_____________________________________________________________________________
231 G4bool G4VAnalysisReader::SetFirstP1Id(G4int f << 273 G4bool G4VAnalysisReader::SetFirstP1Id(G4int firstId) 
232 {                                                 274 {
233   return fVP1Manager->GetHnManager()->SetFirst    275   return fVP1Manager->GetHnManager()->SetFirstId(firstId);
234 }                                              << 276 }  
235                                                   277 
236 //____________________________________________    278 //_____________________________________________________________________________
237 G4bool G4VAnalysisReader::SetFirstP2Id(G4int f << 279 G4bool G4VAnalysisReader::SetFirstP2Id(G4int firstId) 
238 {                                                 280 {
239   return fVP2Manager->GetHnManager()->SetFirst    281   return fVP2Manager->GetHnManager()->SetFirstId(firstId);
240 }                                              << 282 }  
241                                                   283 
242 //____________________________________________    284 //_____________________________________________________________________________
243 G4bool G4VAnalysisReader::SetFirstNtupleId(G4i << 285 G4bool G4VAnalysisReader::SetFirstNtupleId(G4int firstId) 
244 {                                                 286 {
245   return fVNtupleManager->SetFirstId(firstId);    287   return fVNtupleManager->SetFirstId(firstId);
246 }                                              << 288 }  
247                                                   289 
248 //____________________________________________    290 //_____________________________________________________________________________
249 G4int G4VAnalysisReader::GetNtuple(const G4Str << 291 G4int G4VAnalysisReader::GetNtuple(const G4String& ntupleName, 
250                                    const G4Str << 292                                    const G4String& fileName)
251                                    const G4Str << 
252 {                                                 293 {
253   if ( fileName != "" ) {                         294   if ( fileName != "" ) {
254     return fVNtupleManager->ReadNtupleImpl(ntu << 295     return ReadNtupleImpl(ntupleName, fileName, true);
255   }                                               296   }
256   // Check if fileName was set                 << 297   else {  
257   if (fVFileManager->GetFileName() == "") {    << 298     if ( fFileManager->GetFileName() == "" ) {
258     Warn("Cannot read Ntuple " + ntupleName += << 299       G4ExceptionDescription description;
259       "ReadNtuple");                           << 300       description 
260     return kInvalidId;                         << 301         << "Cannot get Ntuple. File name has to be set first.";
261   }                                            << 302       G4Exception("G4VAnalysisReader::GetNtuple()",
262   return fVNtupleManager->ReadNtupleImpl(ntupl << 303                   "Analysis_WR011", JustWarning, description);
263 }                                              << 304       return kInvalidId;
                                                   >> 305     }           
                                                   >> 306     return ReadNtupleImpl(ntupleName, fFileManager->GetFileName(), false);
                                                   >> 307   }  
                                                   >> 308 }                                      
264                                                   309 
265 //____________________________________________    310 //_____________________________________________________________________________
266 G4bool G4VAnalysisReader::SetNtupleIColumn(con << 311 G4bool G4VAnalysisReader::SetNtupleIColumn(const G4String& columnName, 
267                                             G4    312                                             G4int& value)
268 {                                                 313 {
269   return fVNtupleManager->SetNtupleIColumn(col    314   return fVNtupleManager->SetNtupleIColumn(columnName, value);
270 }                                              << 315 }                                              
271                                                   316 
272 //____________________________________________    317 //_____________________________________________________________________________
273 G4bool G4VAnalysisReader::SetNtupleFColumn(con << 318 G4bool G4VAnalysisReader::SetNtupleFColumn(const G4String& columnName, 
274                                             G4    319                                             G4float& value)
275 {                                                 320 {
276   return fVNtupleManager->SetNtupleFColumn(col    321   return fVNtupleManager->SetNtupleFColumn(columnName, value);
277 }                                              << 322 }                                              
278                                                << 323                                             
279 //____________________________________________    324 //_____________________________________________________________________________
280 G4bool G4VAnalysisReader::SetNtupleDColumn(con << 325 G4bool G4VAnalysisReader::SetNtupleDColumn(const G4String& columnName, 
281                                             G4    326                                             G4double& value)
282 {                                                 327 {
283   return fVNtupleManager->SetNtupleDColumn(col    328   return fVNtupleManager->SetNtupleDColumn(columnName, value);
284 }                                              << 329 }                                              
285                                                   330 
286 //____________________________________________    331 //_____________________________________________________________________________
287 G4bool G4VAnalysisReader::SetNtupleSColumn(con << 332 G4bool G4VAnalysisReader::SetNtupleSColumn(const G4String& columnName, 
288                                             G4    333                                             G4String& value)
289 {                                                 334 {
290   return fVNtupleManager->SetNtupleSColumn(col    335   return fVNtupleManager->SetNtupleSColumn(columnName, value);
291 }                                              << 336 }                                              
292                                                   337 
293 //____________________________________________    338 //_____________________________________________________________________________
294 G4bool G4VAnalysisReader::SetNtupleIColumn(con << 339 G4bool G4VAnalysisReader::SetNtupleIColumn(const G4String& columnName, 
295                                             st    340                                             std::vector<int>& vector)
296 {                                                 341 {
297   return fVNtupleManager->SetNtupleIColumn(col    342   return fVNtupleManager->SetNtupleIColumn(columnName, vector);
298 }                                              << 343 }                                              
299                                                << 344                                             
300 //____________________________________________    345 //_____________________________________________________________________________
301 G4bool G4VAnalysisReader::SetNtupleFColumn(con << 346 G4bool G4VAnalysisReader::SetNtupleFColumn(const G4String& columnName, 
302                                             st    347                                             std::vector<float>& vector)
303 {                                                 348 {
304   return fVNtupleManager->SetNtupleFColumn(col    349   return fVNtupleManager->SetNtupleFColumn(columnName, vector);
305 }                                              << 350 }                                              
306                                                << 351                                             
307 //____________________________________________    352 //_____________________________________________________________________________
308 G4bool G4VAnalysisReader::SetNtupleDColumn(con << 353 G4bool G4VAnalysisReader::SetNtupleDColumn(const G4String& columnName, 
309                                             st    354                                             std::vector<double>& vector)
310 {                                                 355 {
311   return fVNtupleManager->SetNtupleDColumn(col    356   return fVNtupleManager->SetNtupleDColumn(columnName, vector);
312 }                                              << 357 }                                              
313                                                << 358                                             
314 //____________________________________________ << 
315 G4bool G4VAnalysisReader::SetNtupleSColumn(con << 
316                                             st << 
317 {                                              << 
318   return fVNtupleManager->SetNtupleSColumn(col << 
319 }                                              << 
320                                                << 
321 //____________________________________________    359 //_____________________________________________________________________________
322 G4bool G4VAnalysisReader::SetNtupleIColumn(G4i    360 G4bool G4VAnalysisReader::SetNtupleIColumn(G4int ntupleId,
323                                             co << 361                                             const G4String& columnName, 
324                                             G4    362                                             G4int& value)
325 {                                                 363 {
326   return fVNtupleManager->SetNtupleIColumn(ntu    364   return fVNtupleManager->SetNtupleIColumn(ntupleId, columnName, value);
327 }                                              << 365 }                                              
328                                                   366 
329 //____________________________________________    367 //_____________________________________________________________________________
330 G4bool G4VAnalysisReader::SetNtupleFColumn(G4i    368 G4bool G4VAnalysisReader::SetNtupleFColumn(G4int ntupleId,
331                                             co << 369                                             const G4String& columnName, 
332                                             G4    370                                             G4float& value)
333 {                                                 371 {
334   return fVNtupleManager->SetNtupleFColumn(ntu    372   return fVNtupleManager->SetNtupleFColumn(ntupleId, columnName, value);
335 }                                              << 373 }                                              
336                                                << 374                                             
337 //____________________________________________    375 //_____________________________________________________________________________
338 G4bool G4VAnalysisReader::SetNtupleDColumn(G4i    376 G4bool G4VAnalysisReader::SetNtupleDColumn(G4int ntupleId,
339                                             co << 377                                             const G4String& columnName, 
340                                             G4    378                                             G4double& value)
341 {                                                 379 {
342   return fVNtupleManager->SetNtupleDColumn(ntu    380   return fVNtupleManager->SetNtupleDColumn(ntupleId, columnName, value);
343 }                                              << 381 }                                              
344                                                   382 
345 //____________________________________________    383 //_____________________________________________________________________________
346 G4bool G4VAnalysisReader::SetNtupleSColumn(G4i    384 G4bool G4VAnalysisReader::SetNtupleSColumn(G4int ntupleId,
347                                             co << 385                                             const G4String& columnName, 
348                                             G4    386                                             G4String& value)
349 {                                                 387 {
350   return fVNtupleManager->SetNtupleSColumn(ntu    388   return fVNtupleManager->SetNtupleSColumn(ntupleId, columnName, value);
351 }                                              << 389 }                                              
352                                                   390 
353 //____________________________________________    391 //_____________________________________________________________________________
354 G4bool G4VAnalysisReader::SetNtupleIColumn(G4i << 392 G4bool G4VAnalysisReader::SetNtupleIColumn(G4int ntupleId, 
355                                             co << 393                                             const G4String& columnName, 
356                                             st    394                                             std::vector<int>& vector)
357 {                                                 395 {
358   return fVNtupleManager->SetNtupleIColumn(ntu    396   return fVNtupleManager->SetNtupleIColumn(ntupleId, columnName, vector);
359 }                                                 397 }
360                                                << 398                                             
361 //____________________________________________    399 //_____________________________________________________________________________
362 G4bool G4VAnalysisReader::SetNtupleFColumn(G4i << 400 G4bool G4VAnalysisReader::SetNtupleFColumn(G4int ntupleId, 
363                                             co << 401                                             const G4String& columnName, 
364                                             st    402                                             std::vector<float>& vector)
365 {                                                 403 {
366   return fVNtupleManager->SetNtupleFColumn(ntu    404   return fVNtupleManager->SetNtupleFColumn(ntupleId, columnName, vector);
367 }                                                 405 }
368                                                   406 
369 //____________________________________________    407 //_____________________________________________________________________________
370 G4bool G4VAnalysisReader::SetNtupleDColumn(G4i << 408 G4bool G4VAnalysisReader::SetNtupleDColumn(G4int ntupleId, 
371                                             co << 409                                             const G4String& columnName, 
372                                             st    410                                             std::vector<double>& vector)
373 {                                                 411 {
374   return fVNtupleManager->SetNtupleDColumn(ntu    412   return fVNtupleManager->SetNtupleDColumn(ntupleId, columnName, vector);
375 }                                                 413 }
376                                                   414 
377 //____________________________________________    415 //_____________________________________________________________________________
378 G4bool G4VAnalysisReader::SetNtupleSColumn(G4i << 
379                                             co << 
380                                             st << 
381 {                                              << 
382   return fVNtupleManager->SetNtupleSColumn(ntu << 
383 }                                              << 
384                                                << 
385 //____________________________________________ << 
386 G4bool G4VAnalysisReader::GetNtupleRow()          416 G4bool G4VAnalysisReader::GetNtupleRow()
387 {                                                 417 {
388   return fVNtupleManager->GetNtupleRow();         418   return fVNtupleManager->GetNtupleRow();
389 }                                              << 419 }                                              
390                                                   420 
391                                                   421 
392 //____________________________________________    422 //_____________________________________________________________________________
393 G4bool G4VAnalysisReader::GetNtupleRow(G4int n    423 G4bool G4VAnalysisReader::GetNtupleRow(G4int ntupleId)
394 {                                                 424 {
395   return fVNtupleManager->GetNtupleRow(ntupleI    425   return fVNtupleManager->GetNtupleRow(ntupleId);
396 }                                              << 426 }                                              
397                                                   427 
398 //____________________________________________    428 //_____________________________________________________________________________
399 G4int G4VAnalysisReader::GetNofH1s(G4bool only << 429 G4int G4VAnalysisReader::GetNofH1s() const
400 {                                                 430 {
401   return fVH1Manager->GetNofHns(onlyIfExist);  << 431   return fVH1Manager->GetHnManager()->GetNofHns();
402 }                                              << 432 }  
403                                                   433 
404 //____________________________________________    434 //_____________________________________________________________________________
405 G4int G4VAnalysisReader::GetNofH2s(G4bool only << 435 G4int G4VAnalysisReader::GetNofH2s() const
406 {                                                 436 {
407   return fVH2Manager->GetNofHns(onlyIfExist);  << 437   return fVH2Manager->GetHnManager()->GetNofHns();
408 }                                              << 438 }  
409                                                   439 
410 //____________________________________________    440 //_____________________________________________________________________________
411 G4int G4VAnalysisReader::GetNofH3s(G4bool only << 441 G4int G4VAnalysisReader::GetNofH3s() const
412 {                                                 442 {
413   return fVH3Manager->GetNofHns(onlyIfExist);  << 443   return fVH3Manager->GetHnManager()->GetNofHns();
414 }                                              << 444 }  
415                                                   445 
416 //____________________________________________    446 //_____________________________________________________________________________
417 G4int G4VAnalysisReader::GetNofP1s(G4bool only << 447 G4int G4VAnalysisReader::GetNofP1s() const
418 {                                                 448 {
419   return fVP1Manager->GetNofHns(onlyIfExist);  << 449   return fVP1Manager->GetHnManager()->GetNofHns();
420 }                                              << 450 }  
421                                                   451 
422 //____________________________________________    452 //_____________________________________________________________________________
423 G4int G4VAnalysisReader::GetNofP2s(G4bool only << 453 G4int G4VAnalysisReader::GetNofP2s() const
424 {                                                 454 {
425   return fVP2Manager->GetNofHns(onlyIfExist);  << 455   return fVP2Manager->GetHnManager()->GetNofHns();
426 }                                              << 456 }  
427                                                   457 
428 //____________________________________________    458 //_____________________________________________________________________________
429 G4int G4VAnalysisReader::GetNofNtuples() const    459 G4int G4VAnalysisReader::GetNofNtuples() const
430 {                                                 460 {
431   return fVNtupleManager->GetNofNtuples();        461   return fVNtupleManager->GetNofNtuples();
432 }                                              << 462 }  
433                                                   463 
434 // GetH1Id(), GetH2Id in .icc                  << 464 // GetH1Id(), GetH2Id in .icc 
435                                                   465 
436 // Access methods in .icc                         466 // Access methods in .icc
437                                                   467 
438 //____________________________________________    468 //_____________________________________________________________________________
439 void G4VAnalysisReader::SetVerboseLevel(G4int  << 469 void G4VAnalysisReader::SetVerboseLevel(G4int verboseLevel) 
440 {                                                 470 {
441   fState.SetVerboseLevel(verboseLevel);           471   fState.SetVerboseLevel(verboseLevel);
442 }                                              << 472 } 
443                                                   473 
444 // GetVerboseLevel() in .icc                   << 474 // GetVerboseLevel() in .icc 
445                                                   475