FairRoot
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
FairUnpack.h
Go to the documentation of this file.
1 /********************************************************************************
2  * Copyright (C) 2014 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
3  * *
4  * This software is distributed under the terms of the *
5  * GNU Lesser General Public Licence (LGPL) version 3, *
6  * copied verbatim in the file "LICENSE" *
7  ********************************************************************************/
8 // -----------------------------------------------------------------------------
9 // ----- -----
10 // ----- FairUnpack -----
11 // ----- Created 12.04.2013 by D.Kresan -----
12 // -----------------------------------------------------------------------------
13 
14 #ifndef FAIRUNPACK_H
15 #define FAIRUNPACK_H
16 
17 #include <Rtypes.h> // for Int_t, Bool_t, etc
18 #include <TObject.h>
19 
20 class FairUnpack : public TObject
21 {
22  public:
23  FairUnpack(Short_t type, Short_t subType, Short_t procId, Short_t subCrate, Short_t control);
24  virtual ~FairUnpack();
25 
26  virtual Bool_t Init() = 0;
27  virtual Bool_t ReInit() { return kTRUE; }
28  virtual Bool_t DoUnpack(Int_t* data, Int_t size) = 0;
29  virtual void Reset() = 0;
30  virtual void SetParContainers(){};
31 
32  inline Short_t GetType() const { return fType; }
33  inline Short_t GetSubType() const { return fSubType; }
34  inline Short_t GetProcId() const { return fProcId; }
35  inline Short_t GetSubCrate() const { return fSubCrate; }
36  inline Short_t GetControl() const { return fControl; }
37 
38  private:
39  Short_t fType;
40  Short_t fSubType;
41  Short_t fProcId;
42  Short_t fSubCrate;
43  Short_t fControl;
44 
45  protected:
46  virtual void Register() = 0;
47 
48  public:
49  ClassDef(FairUnpack, 0);
50 };
51 
52 #endif
virtual void SetParContainers()
Definition: FairUnpack.h:30
virtual Bool_t DoUnpack(Int_t *data, Int_t size)=0
virtual void Reset()=0
virtual Bool_t ReInit()
Definition: FairUnpack.h:27
FairUnpack(Short_t type, Short_t subType, Short_t procId, Short_t subCrate, Short_t control)
Definition: FairUnpack.cxx:16
virtual ~FairUnpack()
Definition: FairUnpack.cxx:25
Short_t GetType() const
Definition: FairUnpack.h:32
virtual void Register()=0
Short_t GetProcId() const
Definition: FairUnpack.h:34
Short_t GetSubType() const
Definition: FairUnpack.h:33
Short_t GetControl() const
Definition: FairUnpack.h:36
ClassDef(FairUnpack, 0)
Short_t GetSubCrate() const
Definition: FairUnpack.h:35
virtual Bool_t Init()=0