1 | /* ======================================================================== *\
|
---|
2 | !
|
---|
3 | ! *
|
---|
4 | ! * This file is part of MARS, the MAGIC Analysis and Reconstruction
|
---|
5 | ! * Software. It is distributed to you in the hope that it can be a useful
|
---|
6 | ! * and timesaving tool in analysing Data of imaging Cerenkov telescopes.
|
---|
7 | ! * It is distributed WITHOUT ANY WARRANTY.
|
---|
8 | ! *
|
---|
9 | ! * Permission to use, copy, modify and distribute this software and its
|
---|
10 | ! * documentation for any purpose is hereby granted without fee,
|
---|
11 | ! * provided that the above copyright notice appear in all copies and
|
---|
12 | ! * that both that copyright notice and this permission notice appear
|
---|
13 | ! * in supporting documentation. It is provided "as is" without express
|
---|
14 | ! * or implied warranty.
|
---|
15 | ! *
|
---|
16 | !
|
---|
17 | !
|
---|
18 | ! Author(s): Thomas Bretz 04/2002 <mailto:tbretz@uni-sw.gwdg.de>
|
---|
19 | !
|
---|
20 | ! Copyright: MAGIC Software Development, 2000-2002
|
---|
21 | !
|
---|
22 | !
|
---|
23 | \* ======================================================================== */
|
---|
24 |
|
---|
25 | /////////////////////////////////////////////////////////////////////////////
|
---|
26 | //
|
---|
27 | // MData
|
---|
28 | //
|
---|
29 | // This base class defines an interface to a generalized value.
|
---|
30 | // This value can be a simple number, it can also be a data member
|
---|
31 | // of a class or some kind of concatenation of MData objects.
|
---|
32 | //
|
---|
33 | // A class inheriting from MData must implement:
|
---|
34 | //
|
---|
35 | // - Double_t GetValue() const
|
---|
36 | // which return the value corresponding to the object
|
---|
37 | //
|
---|
38 | // - Bool_t IsValid() const
|
---|
39 | // should tell whether the object is valid (eg if the object parses
|
---|
40 | // a string the result might be invalid)
|
---|
41 | //
|
---|
42 | // - Bool_t PreProcess(const MParList *plist)
|
---|
43 | // which can be used to get some necessary data (befor processing)
|
---|
44 | // from the parlist.
|
---|
45 | //
|
---|
46 | /////////////////////////////////////////////////////////////////////////////
|
---|
47 |
|
---|
48 | #include "MData.h"
|
---|
49 |
|
---|
50 | #include <fstream.h>
|
---|
51 |
|
---|
52 | ClassImp(MData);
|
---|
53 |
|
---|
54 | Bool_t MData::AsciiWrite(ostream &out) const
|
---|
55 | {
|
---|
56 | out << GetValue() << " ";
|
---|
57 | return kTRUE;
|
---|
58 | }
|
---|
59 |
|
---|