EIC Software
Reference for
EIC
simulation and reconstruction software on GitHub
Home page
Related Pages
Modules
Namespaces
Classes
Files
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
EicEventHeader.h
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file EicEventHeader.h
1
// Tell emacs that this is a C++ source
2
// -*- C++ -*-.
3
#ifndef EICEVENTHEADER_H
4
#define EICEVENTHEADER_H
5
6
#include <
phool/PHObject.h
>
7
8
#include <climits>
9
#include <cmath>
10
#include <iostream>
11
#include <map>
12
#include <string>
13
#include <utility>
14
15
class
EicEventHeader
:
public
PHObject
16
{
17
public
:
18
EicEventHeader
() {}
19
~EicEventHeader
()
override
;
20
21
void
identify
(std::ostream& os = std::cout)
const override
;
22
void
CopyFrom
(
const
PHObject
* phobj)
override
;
23
24
void
Reset
()
override
;
25
26
virtual
void
set_eventgenerator_type
(
const
int
) {
return
; }
27
virtual
int
get_eventgenerator_type
()
const
{
return
-99999; }
28
29
// Milou
30
31
virtual
void
set_milou_weight
(
const
float
) {
return
; }
32
virtual
float
get_milou_weight
()
const
{
return
NAN; }
33
virtual
void
set_milou_trueX
(
const
float
) {
return
; }
34
virtual
float
get_milou_trueX
()
const
{
return
NAN; }
35
virtual
void
set_milou_trueQ2
(
const
float
) {
return
; }
36
virtual
float
get_milou_trueQ2
()
const
{
return
NAN; }
37
38
39
// void set_milou_weight(const float val) override { set_property(prop_milou_weight, val); }
40
// float get_milou_weight() const override { return get_property_float(prop_milou_weight); }
41
42
// DEMP
43
virtual
void
set_demp_weight
(
const
float
) {
return
; }
44
virtual
float
get_demp_weight
()
const
{
return
NAN; }
45
49
enum
PROPERTY
50
{
//
51
prop_eventgen
= 1,
52
prop_milou_weight
= 2,
53
prop_milou_truex
= 3,
54
prop_milou_trueq2
= 4,
55
56
prop_demp_weight
= 5,
57
59
prop_MAX_NUMBER
= UCHAR_MAX
60
};
61
62
enum
PROPERTY_TYPE
63
{
//
64
type_int
= 1,
65
type_uint
= 2,
66
type_float
= 3,
67
type_unknown
= -1
68
};
69
70
enum
EvtGen
71
{
72
Milou
= 1,
73
DEMP
= 2
74
};
75
76
virtual
bool
has_property
(
const
PROPERTY
/*prop_id*/
)
const
{
return
false
; }
77
virtual
float
get_property_float
(
const
PROPERTY
/*prop_id*/
)
const
{
return
NAN; }
78
virtual
int
get_property_int
(
const
PROPERTY
/*prop_id*/
)
const
{
return
INT_MIN; }
79
virtual
unsigned
int
get_property_uint
(
const
PROPERTY
/*prop_id*/
)
const
{
return
UINT_MAX; }
80
virtual
void
set_property
(
const
PROPERTY
/*prop_id*/
,
const
float
/*value*/
) {
return
; }
81
virtual
void
set_property
(
const
PROPERTY
/*prop_id*/
,
const
int
/*value*/
) {
return
; }
82
virtual
void
set_property
(
const
PROPERTY
/*prop_id*/
,
const
unsigned
int
/*value*/
) {
return
; }
83
static
std::pair<const std::string, PROPERTY_TYPE>
get_property_info
(
PROPERTY
prop_id);
84
static
bool
check_property
(
const
PROPERTY
prop_id,
const
PROPERTY_TYPE
prop_type);
85
static
std::string
get_property_type
(
const
PROPERTY_TYPE
prop_type);
86
87
protected
:
88
virtual
unsigned
int
get_property_nocheck
(
const
PROPERTY
/*prop_id*/
)
const
{
return
UINT_MAX; }
89
virtual
void
set_property_nocheck
(
const
PROPERTY
/*prop_id*/
,
const
unsigned
int
) {
return
; }
90
91
std::map<std::string, double>
evInfo
;
92
93
ClassDefOverride(
EicEventHeader
, 1)
94
};
95
96
#endif
fun4all_coresoftware
blob
master
simulation
g4simulation
g4main
EicEventHeader.h
Built by
Jin Huang
. updated:
Mon Jan 22 2024 12:43:49
using
1.8.2 with
EIC GitHub integration