Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PHRawDataNode.cc
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file PHRawDataNode.cc
1 // Implementation of class PHRawDataNode
2 // Author: Matthias Messer
3 
4 #include "PHRawDataNode.h"
5 
6 #include "PHRawOManager.h"
7 
8 #include <phool/PHDataNode.h> // for PHDataNode
9 #include <phool/PHIOManager.h>
10 
11 #include <Event/phenixTypes.h>
12 
14  const int l, const int i, const int w, const int h)
15  : PHDataNode<PHDWORD>(d, n)
16  , length(l)
17  , ID(i)
18  , wordLength(w)
19  , hitFormat(h)
20 {
21 }
22 
24 {
25  // set the data poitner to 0 so
26  // the dtor of the PHDataNode parent class doesn't try
27  // to delete it
28  setData(nullptr);
29 }
30 
32 {
33  PHRawOManager* rawOManager = dynamic_cast<PHRawOManager*>(IOManager);
34  bool bret = false;
35  if (rawOManager)
36  {
37  bret = rawOManager->write(this);
38  }
39 
40  return bret;
41 }