Belle II Software  release-05-02-19
RawPXD.h
1 //+
2 // File : RawPXD.h
3 // Description : pseudo raw data of PXD for test
4 //
5 // Author : Bjoern Spruck / Klemens Lautenbach
6 // Date : 13 - Jul - 2013
7 // Updated 17.7.2015
8 //-
9 
10 #ifndef RAWPXD_H
11 #define RAWPXD_H
12 
13 #include <TObject.h>
14 
15 namespace Belle2 {
28  class RawPXD : public TObject {
29  public:
30 
32  RawPXD();
33 
35  RawPXD(int*, int);
36 
38  RawPXD(const std::vector <unsigned int>& header, const std::vector <std::vector <unsigned char>>& payload);
39 
41  virtual ~RawPXD();
42 
44  virtual int size() const;
45  /*at the moment not used
47  virtual int* allocate_buffer(int nwords);
48 
50  virtual void data(int nwords, int*);
51  */
53  virtual int* data(void);
54 
56  std::string getInfoHTML() const;
57 
58  private:
59  int m_nwords;
60  int* m_buffer; //[m_nwords] /**< Buffer of size m_nwords */
62 
64  static unsigned int endian_swap(unsigned int x);
65 
66  ClassDef(RawPXD, 2)
67  }; // class RawPXD
68 
69 
71 } // end namespace Belle2
72 
73 #endif
Belle2::RawPXD::size
virtual int size() const
get size of buffer in 32 Bit words
Definition: RawPXD.cc:76
Belle2::RawPXD::m_buffer
int * m_buffer
Raw dump of ONSEN data. buffer of size m_nwords (32bit int)
Definition: RawPXD.h:61
Belle2::RawPXD::m_nwords
int m_nwords
Number of (32bit) Words stored in the buffer.
Definition: RawPXD.h:59
Belle2::RawPXD::getInfoHTML
std::string getInfoHTML() const
Return a short summary of this object's contents in HTML format.
Definition: RawPXD.cc:87
Belle2::RawPXD::RawPXD
RawPXD()
Default constructor.
Definition: RawPXD.cc:16
Belle2::RawPXD
The Raw PXD class.
Definition: RawPXD.h:28
Belle2
Abstract base class for different kinds of events.
Definition: MillepedeAlgorithm.h:19
Belle2::RawPXD::endian_swap
static unsigned int endian_swap(unsigned int x)
Endian swap a int32.
Definition: RawPXD.cc:28
Belle2::RawPXD::data
virtual int * data(void)
get pointer to data
Definition: RawPXD.cc:81
Belle2::RawPXD::~RawPXD
virtual ~RawPXD()
Destructor.
Definition: RawPXD.cc:71