NSCL DDAS  1.0
Support for XIA DDAS at the NSCL
 All Classes Namespaces Files Functions Variables Macros Pages
MyParameterMapper.h
1 
2 
3 #ifndef MYPARAMETERMAPPER_H
4 #define MYPARAMETERMAPPER_H
5 
6 #include <ParameterMapper.h>
7 
8 #include <map>
9 
10 // SpecTcl event, we don't use it
11 class CEvent;
12 
13 // The strucutre of tree parameters
14 class MyParameters;
15 
16 
17 // Class responsible for mapping DDAS hit data to SpecTcl TreeParameters
18 //
19 // It operates on a MyParameters structure containing TreeParameters but
20 // does not own it.
21 class MyParameterMapper : public DAQ::DDAS::CParameterMapper
22 {
23  private:
24  MyParameters& m_params; // reference to the tree parameter structure
25  std::map<int, int> m_chanMap; // global channel index for crates
26 
27  public:
28  // Constructor.
29  //
30  // \param params the data structure
32 
33  // Map raw hit data to TreeParameters
34  //
35  // \param channelData the hit data
36  // \param rEvent the SpecTcl event
37  virtual void mapToParameters(const std::vector<DAQ::DDAS::DDASHit>& channelData,
38  CEvent& rEvent);
39 
40  // Compute channel index from crate, slot, and channel information
41  //
42  // \param hit the ddas hit
43  int computeGlobalIndex(const DAQ::DDAS::DDASHit& hit);
44 };
45 #endif
46 
Encapsulation of a generic DDAS event.
Definition: DDASHit.h:51
Definition: MyParameterMapper.h:21
Definition: MyParameters.h:55