source: trunk/MagicSoft/MarsOctober/mbase/MFileDescr.h@ 8955

Last change on this file since 8955 was 447, checked in by harald, 24 years ago
Bringing the sources for the octobertest under CVS controll. (november, 3rd, 2000)
  • Property svn:executable set to *
File size: 1.6 KB
Line 
1#ifndef MFILEDESCR_H
2#define MFILEDESCR_H
3
4#include "Magic.h"
5
6#include <fstream.h>
7
8class TFile;
9class TTree;
10class TBranch;
11class MParContainer;
12
13class MFileDescrIn
14{
15public:
16 virtual void SetAddress(MParContainer **obj) {};
17 virtual void GetEvent(Int_t n) {};
18};
19
20class MFileDescrOut
21{
22public:
23 virtual void SetAddress(MParContainer **obj) {};
24 virtual void Fill() {};
25};
26
27class MRootFileIn : public MFileDescrIn
28{
29private:
30 TTree *pTreeIn; // tree to open for input
31 TBranch *pBranchIn; // branch to open for input
32
33 Int_t nEvts; // in Tree
34
35public:
36 MRootFileIn(TFile *f, const char *fName, const char *cname);
37 void SetAddress(MParContainer **obj);
38 void GetEvent(Int_t n);
39};
40
41class MRootFileOut : public MFileDescrOut
42{
43private:
44 TTree *pTreeOut; // tree to open for output
45 TBranch *pBranchOut; // branch to open for output
46
47public:
48 MRootFileOut(const char *fName, const char *cname, MParContainer **obj);
49 void SetAddress(MParContainer **obj);
50 void Fill();
51};
52
53/* -------------------- Magic File --------------------- */
54
55class MMagicFileIn : public MFileDescrIn
56{
57private:
58 fstream *fin;
59 MParContainer *fContainer; // tree to open for input
60
61public:
62 MMagicFileIn(const char *fname);
63 ~MMagicFileIn();
64
65 void SetAddress(MParContainer **obj);
66 void GetEvent(Int_t n=0);
67};
68
69class MMagicFileOut : public MFileDescrOut
70{
71private:
72 fstream *fout;
73 MParContainer *fContainer;
74
75public:
76 MMagicFileOut(const char *fname, MParContainer **obj);
77 ~MMagicFileOut();
78
79 void SetAddress(MParContainer **obj);
80 void Fill();
81};
82
83#endif
Note: See TracBrowser for help on using the repository browser.