Belle II Software development
DQMHistAnalysisInputPVSrv.h
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8//+
9// File : DQMHistAnalysisInputPVSrv.h
10// Description : Input module for DQM Histogram analysis
11//-
12
13#pragma once
14
15#include <framework/dataobjects/EventMetaData.h>
16#include <framework/datastore/StoreObjPtr.h>
17
18#include <dqm/core/DQMHistAnalysis.h>
19
20namespace Belle2 {
26
27#ifdef _BELLE2_EPICS
28#define MAX_PV_NAME_LEN 40
29
30 typedef struct {
31 char name[MAX_PV_NAME_LEN];
32 chid mychid;
33 evid myevid;
34 bool changed;
35 TH1* histo;
36 unsigned int binx; // not needed until now
37 unsigned int biny; // not needed until now
38 unsigned int binmax; // store bincount to prevent overflow
39 } MYNODE;
40#endif
41
43
44 // Public functions
45 public:
46
51
55 void initialize() override final;
56
60 void beginRun() override final;
61
65 void event() override final;
66
70 void endRun() override final;
71
75 void terminate() override final;
76
77 // Data members
78 private:
85 //THttpServer* m_serv{0};
86 //int m_nhist = 0;
87
89 std::vector< std::vector<std::string>> m_histlist;
90
91#ifdef _BELLE2_EPICS
92 std::vector<MYNODE*> pmynode;
93#endif
94
97
99 unsigned int m_expno = 0;
101 unsigned int m_runno = 0;
103 unsigned int m_count = 0;
104 };
105
106} // end namespace Belle2
107
void initialize() override final
Definition of the histograms.
void terminate() override final
This method is called at the end of the event processing.
void event() override final
This method is called for each event.
void endRun() override final
This method is called if the current run ends.
bool m_server
Whether to start http server on port 8082.
std::vector< std::vector< std::string > > m_histlist
Parameter list for histograms.
void beginRun() override final
Called when entering a new run.
StoreObjPtr< EventMetaData > m_eventMetaDataPtr
The metadata for each event.
bool m_callback
Whether to use EPICS callback for changes.
DQMHistAnalysisModule()
Constructor / Destructor.
Type-safe access to single objects in the data store.
Definition StoreObjPtr.h:96
Abstract base class for different kinds of events.