CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ALIFileOut.h
Go to the documentation of this file.
1 // COCOA class header file
2 //Id: ALIFileOut.h
3 //CAT: Model
4 //
5 // ostream class for handling the output
6 //
7 // History: v1.0
8 // Pedro Arce
9 
10 #ifndef FILEOUT_H
11 #define FILEOUT_H
12 
13 #include <fstream>
14 #include <iostream>
15 
16 #include <vector>
17 //#include "bstring.h"
18 
20 
21 
22 class ALIFileOut : public std::ofstream
23 {
24 public:
26  ALIFileOut( const ALIstring& name ): std::ofstream(), theName(name){};
28 
29  // get the instance of file with name filename
30  static ALIFileOut& getInstance( const ALIstring& filename );
31 
32  // Access data members
33  const ALIstring& name() { return theName; }
34 
35 // private DATA MEMEBERS
36 private:
37  // Class only instance
38  static std::vector<ALIFileOut*> theInstances;
39 
42 };
43 
44 #endif
45 
ALIFileOut(const ALIstring &name)
Definition: ALIFileOut.h:26
const ALIstring & name()
Definition: ALIFileOut.h:33
ALIstring theName
Name of file.
Definition: ALIFileOut.h:41
static std::vector< ALIFileOut * > theInstances
Definition: ALIFileOut.h:38
std::string ALIstring
Definition: CocoaGlobals.h:9
tuple filename
Definition: lut2db_cfg.py:20
static ALIFileOut & getInstance(const ALIstring &filename)
Definition: ALIFileOut.cc:19