MARLEY (Model of Argon Reaction Low Energy Yields) v2.0.0
A Monte Carlo event generator for tens-of-MeV neutrino interactions
Loading...
Searching...
No Matches
Print.h
1// -*- C++ -*-
2//
3// This file is part of HepMC
4// Copyright (C) 2014-2023 The HepMC collaboration (see AUTHORS for details)
5//
6#ifndef HEPMC3_PRINT_H
7#define HEPMC3_PRINT_H
12
13#include "HepMC3/GenEvent.h"
14#include "HepMC3/GenRunInfo.h"
15#include "HepMC3/GenVertex.h"
16#include "HepMC3/GenParticle.h"
17
18namespace HepMC3 {
19
20
21class GenPdfInfo;
22class GenHeavyIon;
23class GenCrossSection;
24
25
27class Print {
28public:
30 static void content(std::ostream& os, const GenEvent &event);
32 inline static void content(const GenEvent &event) { content(std::cout, event); }
33
35 static void listing(std::ostream& os, const GenEvent &event, unsigned short precision = 2);
37 inline static void listing(const GenEvent &event, unsigned short precision = 2) {
38 listing(std::cout, event, precision);
39 }
40
42 static void listing(std::ostream& os, const GenRunInfo &ri, unsigned short precision = 2);
44 inline static void listing(const GenRunInfo &ri, unsigned short precision = 2) {
45 listing(std::cout, ri, precision);
46 }
47
49 static void line(std::ostream& os, const GenEvent &event, bool attributes=false);
51 inline static void line(const GenEvent &event, bool attributes=false) {
52 line(std::cout, event, attributes);
53 std::cout<<std::endl;
54 }
55
57 static void line(std::ostream& os, const GenRunInfo &RunInfo, bool attributes=false);
59 inline static void line(const GenRunInfo &RunInfo, bool attributes=false) {
60 line(std::cout, RunInfo, attributes);
61 std::cout<<std::endl;
62 }
63
65 static void line(std::ostream& os, const GenRunInfo::ToolInfo& t);
67 inline static void line(const GenRunInfo::ToolInfo& t) {
68 line(std::cout, t);
69 std::cout << std::endl;
70 }
71
72
73
75 static void line(std::ostream& os, ConstGenVertexPtr v, bool attributes=false);
77 inline static void line(ConstGenVertexPtr v, bool attributes=false) {
78 line(std::cout, v, attributes);
79 std::cout << std::endl;
80 }
81
83 static void line(std::ostream& os, GenVertexPtr v, bool attributes=false);
85 inline static void line(GenVertexPtr v, bool attributes=false) {
86 line(std::cout, v, attributes);
87 std::cout << std::endl;
88 }
89
91 static void line(std::ostream& os, const FourVector& p);
93 inline static void line(const FourVector& p) {
94 line(std::cout, p);
95 std::cout << std::endl;
96 }
97
99 static void line(std::ostream& os, ConstGenParticlePtr p, bool attributes=false);
101 inline static void line(ConstGenParticlePtr p, bool attributes=false) {
102 line(std::cout, p, attributes);
103 std::cout << std::endl;
104 }
105
107 static void line(std::ostream& os, GenParticlePtr p, bool attributes=false);
109 inline static void line(GenParticlePtr p, bool attributes=false) {
110 line(std::cout, p, attributes);
111 std::cout << std::endl;
112 }
113
114
116 static void line(std::ostream& os, std::shared_ptr<GenCrossSection> &cs);
118 inline static void line(std::shared_ptr<GenCrossSection> &cs) {
119 line(std::cout, cs);
120 std::cout<<std::endl;
121 }
122
124 static void line(std::ostream& os, std::shared_ptr<GenHeavyIon> &hi);
126 inline static void line(std::shared_ptr<GenHeavyIon> &hi) {
127 line(std::cout, hi);
128 std::cout<<std::endl;
129 }
130
132 static void line(std::ostream& os, std::shared_ptr<GenPdfInfo> &pi);
134 inline static void line(std::shared_ptr<GenPdfInfo> &pi) {
135 line(std::cout, pi);
136 std::cout<<std::endl;
137 }
138
139 Print& operator = (const Print &) = delete;
140
141private:
143 static void listing(std::ostream& os, ConstGenVertexPtr v);
144
145
147 static void listing(std::ostream& os, ConstGenParticlePtr p);
148
150 virtual ~Print() {}
151};
152} // namespace HepMC3
153
154#endif
Generic 4-vector.
Definition FourVector.h:36
Stores additional information about cross-section.
Stores event-related information.
Definition GenEvent.h:47
Stores additional information about Heavy Ion generator.
Definition GenHeavyIon.h:26
Stores additional information about PDFs.
Definition GenPdfInfo.h:32
Stores run-related information.
Definition GenRunInfo.h:33
Interrnal struct for keeping track of tools.
Definition GenRunInfo.h:38
Provides different printing formats.
Definition Print.h:27
static void line(GenVertexPtr v, bool attributes=false)
Print one-line info to std::cout.
Definition Print.h:85
static void content(std::ostream &os, const GenEvent &event)
Print content of all GenEvent containers.
static void listing(const GenEvent &event, unsigned short precision=2)
Print event in listing (HepMC2) format to std::cout.
Definition Print.h:37
static void line(ConstGenParticlePtr p, bool attributes=false)
Print one-line info to std::cout.
Definition Print.h:101
static void line(ConstGenVertexPtr v, bool attributes=false)
Print one-line info to std::cout.
Definition Print.h:77
static void line(const GenEvent &event, bool attributes=false)
Print one-line info to std::cout.
Definition Print.h:51
static void line(std::shared_ptr< GenCrossSection > &cs)
Print one-line info to std::cout.
Definition Print.h:118
static void line(std::ostream &os, const GenEvent &event, bool attributes=false)
Print one-line info.
static void line(const FourVector &p)
Print one-line info to std::cout.
Definition Print.h:93
static void line(std::shared_ptr< GenPdfInfo > &pi)
Print one-line info to std::cout.
Definition Print.h:134
static void line(const GenRunInfo &RunInfo, bool attributes=false)
Print one-line info to std::cout.
Definition Print.h:59
static void line(std::shared_ptr< GenHeavyIon > &hi)
Print one-line info to std::cout.
Definition Print.h:126
static void line(const GenRunInfo::ToolInfo &t)
Print one-line info to std::cout.
Definition Print.h:67
static void listing(std::ostream &os, const GenEvent &event, unsigned short precision=2)
Print event in listing (HepMC2) format.
static void listing(const GenRunInfo &ri, unsigned short precision=2)
Print runinfo in listing to std::cout.
Definition Print.h:44
static void content(const GenEvent &event)
Print content of all GenEvent containers to std::cout.
Definition Print.h:32
static void line(GenParticlePtr p, bool attributes=false)
Print one-line info to std::cout.
Definition Print.h:109
Print & operator=(const Print &)=delete
deleted copy assignment operator