SimDataFormats
GeneratorProducts
src
hepmc_rootio.cc
Go to the documentation of this file.
1
#include <HepMC/GenParticle.h>
2
#include <HepMC/GenVertex.h>
3
#include <iostream>
4
5
//HACK We need to change the internals of GenVertex when reading
6
// back via ROOT. We use the private access of GenEvent to
7
// accomplish it.
8
namespace
HepMC
{
9
class
GenEvent
{
10
public
:
11
static
void
clear_particles_in
(HepMC::GenVertex* iVertex) {
12
iVertex->m_particles_in.clear();
13
}
14
static
void
add_to_particles_in
(HepMC::GenVertex* iVertex,
HepMC::GenParticle
* iPart) {
15
iVertex->m_particles_in.push_back(iPart);
16
}
17
};
18
}
19
20
21
namespace
hepmc_rootio
{
22
void
add_to_particles_in
(HepMC::GenVertex* iVertex,
HepMC::GenParticle
* iPart) {
23
HepMC::GenEvent::add_to_particles_in
(iVertex, iPart);
24
}
25
26
void
clear_particles_in
(HepMC::GenVertex* iVertex) {
27
HepMC::GenEvent::clear_particles_in
(iVertex);
28
}
29
}
hepmc_rootio
Definition:
classes.h:26
hepmc_rootio::add_to_particles_in
void add_to_particles_in(HepMC::GenVertex *, HepMC::GenParticle *)
Definition:
hepmc_rootio.cc:22
HepMC::GenEvent
Definition:
hepmc_rootio.cc:9
HepMC::GenEvent::clear_particles_in
static void clear_particles_in(HepMC::GenVertex *iVertex)
Definition:
hepmc_rootio.cc:11
GenParticle.GenParticle
GenParticle
Definition:
GenParticle.py:18
hepmc_rootio::clear_particles_in
void clear_particles_in(HepMC::GenVertex *)
Definition:
hepmc_rootio.cc:26
HepMC
Definition:
GenParticle.h:15
HepMC::GenEvent::add_to_particles_in
static void add_to_particles_in(HepMC::GenVertex *iVertex, HepMC::GenParticle *iPart)
Definition:
hepmc_rootio.cc:14
Generated for CMSSW Reference Manual by
1.8.16