]> git.uio.no Git - u/mrichter/AliRoot.git/blame - RAW/AliRawReaderMemory.h
Decoding of the sampling time and L1 phase.
[u/mrichter/AliRoot.git] / RAW / AliRawReaderMemory.h
CommitLineData
7ab595b2 1#ifndef ALIRAWREADERMEMORY_H
2#define ALIRAWREADERMEMORY_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
7
8///////////////////////////////////////////////////////////////////////////////
9///
10/// This is a class for reading raw data memory.
11///
12///////////////////////////////////////////////////////////////////////////////
13
14#include "AliRawReader.h"
15#ifdef __CINT__
16class fstream;
17#else
18#include <Riostream.h>
19#endif
20#include <TString.h>
21
22
23class AliRawReaderMemory: public AliRawReader {
24 public :
25 AliRawReaderMemory();
26 AliRawReaderMemory(UChar_t* memory, UInt_t size);
27/* AliRawReaderMemory(const AliRawReaderMemory& rawReader); */
28/* AliRawReaderMemory& operator = (const AliRawReaderMemory& rawReader); */
29 virtual ~AliRawReaderMemory();
30
299738b9 31 virtual void RequireHeader(Bool_t required);
32
7ab595b2 33 virtual UInt_t GetType() const {return 0;};
34 virtual UInt_t GetRunNumber() const {return 0;};
35 virtual const UInt_t* GetEventId() const {return 0;};
36 virtual const UInt_t* GetTriggerPattern() const {return 0;};
37 virtual const UInt_t* GetDetectorPattern() const {return 0;};
38 virtual const UInt_t* GetAttributes() const {return 0;};
39 virtual const UInt_t* GetSubEventAttributes() const {return 0;};
40 virtual UInt_t GetLDCId() const {return 0;};
41 virtual UInt_t GetGDCId() const {return 0;};
741c154c 42 virtual UInt_t GetTimestamp() const {return 0;};
7ab595b2 43
76a7ad7a 44 virtual Int_t GetEquipmentSize() const {return fBufferSize;};
7ab595b2 45 virtual Int_t GetEquipmentType() const {return 0;};
012425c9 46 virtual Int_t GetEquipmentId() const {return fEquipmentId;};
7ab595b2 47 virtual const UInt_t* GetEquipmentAttributes() const {return NULL;};
48 virtual Int_t GetEquipmentElementSize() const {return 0;};
299738b9 49 virtual Int_t GetEquipmentHeaderSize() const {return 0;};
7ab595b2 50
51 virtual Bool_t ReadHeader();
52 virtual Bool_t ReadNextData(UChar_t*& data);
bf22797a 53 virtual Bool_t ReadNext(UChar_t* data, Int_t size);
7ab595b2 54
55 virtual Bool_t Reset();
56
57 virtual Bool_t NextEvent();
58 virtual Bool_t RewindEvents();
59
012425c9 60 virtual Bool_t SetMemory( UChar_t* memory, ULong_t size );
61
62 void SetEquipmentID(Int_t id) { fEquipmentId = id; }
7ab595b2 63
64 protected :
65
66 UChar_t* fBuffer; // buffer for payload
012425c9 67 UInt_t fBufferSize; // size of fBuffer in bytes
68 UInt_t fPosition; // Current position in memory
69 Int_t fEquipmentId; // Equipment id provided by the user
7ab595b2 70
7ab595b2 71 ClassDef(AliRawReaderMemory, 0) // class for reading raw digits from a memory block
72
73 private:
74
75 AliRawReaderMemory(const AliRawReaderMemory& rawReader);
76 AliRawReaderMemory& operator = (const AliRawReaderMemory& rawReader);
77};
78
79#endif
76a7ad7a 80