]>
Commit | Line | Data |
---|---|---|
324b1730 | 1 | #ifndef ALI_SURVEY_OBJ_H |
2 | #define ALI_SURVEY_OBJ_H | |
3 | ||
4 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
5 | * See cxx source for full Copyright notice */ | |
6 | ||
7 | ///////////////////////////////////////////////////////////////////// | |
8 | // // | |
9 | // class AliSurveyObj // | |
10 | // Retrieve and Convert survey data into ROOT Objects // | |
11 | // // | |
12 | ///////////////////////////////////////////////////////////////////// | |
13 | ||
14 | #include <TObject.h> | |
15 | //#include <sstream> | |
16 | ||
17 | #include <TString.h> | |
18 | #include <TObjArray.h> | |
19 | ||
20 | //#include "AliLog.h" | |
21 | #include "AliSurveyPoint.h" | |
22 | ||
23 | class AliSurveyObj: public TObject { | |
24 | ||
25 | public: | |
26 | AliSurveyObj(); | |
27 | ~AliSurveyObj(); | |
573b6a5a | 28 | Bool_t FillFromLocalFile(const Char_t* filename); |
adfef030 | 29 | Bool_t Fill(TString detector, Int_t year, Int_t reportNumber, |
30 | Int_t reportVersion); | |
31 | ||
324b1730 | 32 | |
33 | ||
34 | Int_t GetEntries() const {return fDataPoints->GetEntries();}; | |
573b6a5a | 35 | |
36 | TString GetReportTitle() const {return fTitle;}; | |
37 | TString GetReportDate() const {return fDate;}; | |
38 | TString GetDetector() const {return fDetector;}; | |
39 | TString GetURL() const {return fURL;}; | |
40 | Int_t GetReportNumber() const {return fReportNr;}; | |
41 | Int_t GetReportVersion() const {return fVersion;}; | |
42 | TString GetObservations() const {return fObs;}; | |
43 | TString GetCoordSys() const {return fCoordSys;}; | |
44 | TString GetUnits() const {return fUnits;}; | |
45 | Int_t GetNrColumns() const {return fNrColumns;}; | |
46 | TObjArray *GetColumnNames() const {return fColNames.Tokenize(',');}; | |
47 | TObjArray *GetData() const {return fDataPoints;}; | |
48 | ||
324b1730 | 49 | Bool_t IsValid() const {return fIsValid;}; |
50 | ||
51 | ||
52 | private: | |
53 | TString fTitle; // Report Title | |
54 | TString fDate; // Report Date | |
55 | TString fDetector; // Subdetector (or structure) surveyed | |
56 | TString fURL; // Report URL in EDMS | |
57 | Int_t fReportNr; // Report Number | |
58 | Int_t fVersion; // Report Version | |
59 | TString fObs; // General observations / comments | |
60 | TString fCoordSys; // Measurements coordinate system | |
61 | TString fUnits; // Measurements units | |
62 | Int_t fNrColumns; // Number of columns in data values | |
63 | TString fColNames; // Column names sepparated by commas | |
64 | Bool_t fIsValid; // Is the data valid? (sucessfully parsed) | |
65 | ||
66 | TObjArray *fDataPoints; // Actual Data | |
67 | ||
68 | Bool_t Connect(const char *gridUrl, const char *user); | |
69 | Bool_t OpenFile(TString openString); | |
70 | TString &Sanitize(TString str); | |
71 | Bool_t ParseBuffer(const Char_t* buf); | |
adfef030 | 72 | void Reset(); |
73 | ||
324b1730 | 74 | AliSurveyObj (const AliSurveyObj& surveyObj); // copy constructor |
75 | AliSurveyObj& operator=(const AliSurveyObj& surveyObj); // assignment operator | |
76 | void AddPoint(AliSurveyPoint* point); | |
adfef030 | 77 | |
324b1730 | 78 | ClassDef(AliSurveyObj, 1); |
79 | }; | |
80 | ||
81 | #endif |