Belle II Software
light-2406-ragdoll
EventExtraInfo.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
#pragma once
10
11
#include <map>
12
13
#include <TObject.h>
14
15
namespace
Belle2
{
25
class
EventExtraInfo
:
public
TObject {
26
27
public
:
32
float
getExtraInfo
(
const
std::string& name)
const
;
33
35
bool
hasExtraInfo
(
const
std::string& name)
const
;
36
37
39
void
removeExtraInfo
();
40
45
void
addExtraInfo
(
const
std::string& name,
float
value);
46
51
void
setExtraInfo
(
const
std::string& name,
float
value);
52
54
std::string
getInfoHTML
()
const
;
55
57
std::vector<std::string>
getNames
()
const
;
58
59
64
std::string
getExtraStringInfo
(
const
std::string& name)
const
;
65
67
bool
hasExtraStringInfo
(
const
std::string& name)
const
;
68
69
71
void
removeExtraStringInfo
();
72
77
void
addExtraStringInfo
(
const
std::string& name,
const
std::string& value);
78
83
void
setExtraStringInfo
(
const
std::string& name,
const
std::string& value);
84
86
std::vector<std::string>
getStringInfoNames
()
const
;
87
90
void
addEventType
(
const
std::string& eventType)
91
{
92
addExtraStringInfo
(std::string(
"eventType"
), eventType);
93
};
94
97
std::string
getEventType
()
const
;
98
99
private
:
100
std::map<std::string, float>
eventExtraInfo
;
102
std::map<std::string, std::string>
eventExtraStringInfo
;
104
ClassDef
(
EventExtraInfo
, 3);
105
// v3. Add m_eventType
106
};
107
109
}
// end namespace Belle2
110
Belle2::EventExtraInfo
Class to stores ExtraInfo of the whole event.
Definition:
EventExtraInfo.h:25
Belle2::EventExtraInfo::removeExtraInfo
void removeExtraInfo()
Removes extra info from event.
Definition:
EventExtraInfo.cc:29
Belle2::EventExtraInfo::getExtraStringInfo
std::string getExtraStringInfo(const std::string &name) const
Return given value if set.
Definition:
EventExtraInfo.cc:66
Belle2::EventExtraInfo::eventExtraStringInfo
std::map< std::string, std::string > eventExtraStringInfo
map variable names to values for string data type.
Definition:
EventExtraInfo.h:102
Belle2::EventExtraInfo::getExtraInfo
float getExtraInfo(const std::string &name) const
Return given value if set.
Definition:
EventExtraInfo.cc:16
Belle2::EventExtraInfo::eventExtraInfo
std::map< std::string, float > eventExtraInfo
map variable names to values.
Definition:
EventExtraInfo.h:100
Belle2::EventExtraInfo::hasExtraStringInfo
bool hasExtraStringInfo(const std::string &name) const
Return whether the extra string info with the given name is set.
Definition:
EventExtraInfo.cc:73
Belle2::EventExtraInfo::hasExtraInfo
bool hasExtraInfo(const std::string &name) const
Return whether the extra info with the given name is set.
Definition:
EventExtraInfo.cc:23
Belle2::EventExtraInfo::getEventType
std::string getEventType() const
Get the event type information.
Definition:
EventExtraInfo.cc:105
Belle2::EventExtraInfo::addExtraStringInfo
void addExtraStringInfo(const std::string &name, const std::string &value)
Sets the user-defined data of given name to the given value.
Definition:
EventExtraInfo.cc:84
Belle2::EventExtraInfo::addEventType
void addEventType(const std::string &eventType)
Add the event type information.
Definition:
EventExtraInfo.h:90
Belle2::EventExtraInfo::removeExtraStringInfo
void removeExtraStringInfo()
Removes extra string info from event.
Definition:
EventExtraInfo.cc:79
Belle2::EventExtraInfo::addExtraInfo
void addExtraInfo(const std::string &name, float value)
Sets the user-defined data of given name to the given value.
Definition:
EventExtraInfo.cc:34
Belle2::EventExtraInfo::setExtraStringInfo
void setExtraStringInfo(const std::string &name, const std::string &value)
Sets the user-defined data of given name to the given value.
Definition:
EventExtraInfo.cc:92
Belle2::EventExtraInfo::ClassDef
ClassDef(EventExtraInfo, 3)
Class to store event extra info.
Belle2::EventExtraInfo::getStringInfoNames
std::vector< std::string > getStringInfoNames() const
Grab the names in this event extra string info (for printing etc)
Definition:
EventExtraInfo.cc:97
Belle2::EventExtraInfo::getNames
std::vector< std::string > getNames() const
Grab the names in this event extra info (for printing etc)
Definition:
EventExtraInfo.cc:56
Belle2::EventExtraInfo::getInfoHTML
std::string getInfoHTML() const
Return a short summary of this object's contents in HTML format.
Definition:
EventExtraInfo.cc:47
Belle2::EventExtraInfo::setExtraInfo
void setExtraInfo(const std::string &name, float value)
Sets the user-defined data of given name to the given value.
Definition:
EventExtraInfo.cc:42
Belle2
Abstract base class for different kinds of events.
Definition:
ClusterUtils.h:24
framework
dataobjects
include
EventExtraInfo.h
Generated on Tue Jul 9 2024 23:28:21 for Belle II Software by
1.9.6