FairRoot/PandaRoot
Functions
parfiletest.C File Reference

Go to the source code of this file.

Functions

void parfiletest (string Filename, Int_t iMaxValues)
 

Function Documentation

void parfiletest ( string  Filename,
Int_t  iMaxValues 
)

Definition at line 3 of file parfiletest.C.

References Double_t.

4 {
5  string InputBuffer;
6  char* pEnd;
7  Double_t Value1;
8  Double_t *Values = new Double_t[16];
9 
10  ifstream InputFile;
11  InputFile.open(Filename.data());
12 
13  if (!InputFile)
14  {
15 
16  cout << "File does not exist" << endl;
17  }
18  else if (InputFile.good())
19  {
20  getline(InputFile,InputBuffer);
21  cout << InputBuffer << endl;
22  pEnd = InputBuffer.data();
23  for (Int_t iValues = 0; iValues < iMaxValues; iValues++)
24  {
25  Values[iValues = strtod(pEnd,&pEnd);
26 
27  cout << "Value_" << iValues <<": " <<Value1 << endl<<endl;
28  //cout << pEnd << endl;
29  };
30  }
31 
32 
33 }
Double_t