FairRoot
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
FairTestOutputHandler.h
Go to the documentation of this file.
1 /********************************************************************************
2  * Copyright (C) 2014 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
3  * *
4  * This software is distributed under the terms of the *
5  * GNU Lesser General Public Licence (LGPL) version 3, *
6  * copied verbatim in the file "LICENSE" *
7  ********************************************************************************/
8 #ifndef FAIRTESTOUTPUTHANDLER_H_
9 #define FAIRTESTOUTPUTHANDLER_H_
10 #pragma once
11 
12 #include <string>
13 #include <vector>
14 
16 {
17  public:
18  FairTestOutputHandler(const std::string& filename);
21 
22  std::string GetCaptureLine(int line);
23  int GetNumberOfLines();
24 
25  void SetFileName(const std::string& filename);
26 
27  private:
28  void ReadContentFromFile();
29 
30  std::string fFileName;
31  std::vector<std::string> fFileContent;
32  std::vector<std::string>::iterator fFileContentIterator;
33  int fNumberOfLines;
34  bool fFileAlreadyRead;
35 };
36 
37 #endif
std::string GetCaptureLine(int line)
void SetFileName(const std::string &filename)