HepMC3 event record library
|
Go to the documentation of this file.
9 #ifndef HEPMC3_GENVERTEX_H
10 #define HEPMC3_GENVERTEX_H
12 #include "HepMC3/GenParticle_fwd.h"
13 #include "HepMC3/GenVertex_fwd.h"
26 class GenVertex :
public std::enable_shared_from_this<GenVertex> {
55 bool in_event()
const {
return parent_event() !=
nullptr; }
60 int id()
const {
return m_id; }
66 int status()
const {
return m_data.status; }
74 void add_particle_in ( GenParticlePtr p);
76 void add_particle_out( GenParticlePtr p);
78 void remove_particle_in ( GenParticlePtr p);
80 void remove_particle_out( GenParticlePtr p);
83 const vector<GenParticlePtr>&
particles_in() {
return m_particles_in; }
85 const vector<ConstGenParticlePtr>& particles_in()
const;
87 const vector<GenParticlePtr>&
particles_out() {
return m_particles_out; }
89 const vector<ConstGenParticlePtr>& particles_out()
const;
109 bool add_attribute(
const string& name, shared_ptr<Attribute> att);
112 vector<string> attribute_names()
const;
115 void remove_attribute(
const string& name);
119 shared_ptr<T> attribute(
const string& name)
const;
122 string attribute_as_string(
const string& name)
const;
vector< GenParticlePtr > m_particles_out
Outgoing particle list.
Definition of class GenEvent.
void set_status(int stat)
Set vertex status code.
Stores event-related information.
GenEvent * parent_event()
Get parent event.
const vector< GenParticlePtr > & particles_out()
Get list of outgoing particles.
void add_particle_out(GenParticle *p)
Stores serializable vertex information.
static const FourVector & ZERO_VECTOR()
Static null FourVector = (0,0,0,0)
Definition of class FourVector.
const GenEvent * parent_event() const
Get parent event.
vector< GenParticlePtr > m_particles_in
Incoming particle list.
bool in_event() const
Check if this vertex belongs to an event.
shared_ptr< T > attribute(const string &name, const int &id=0) const
Get attribute of type T.
bool has_set_position() const
Check if position of this vertex is set.
Stores vertex-related information.
void add_particle_in(GenParticle *p)
Definition of class GenVertexData.
const GenVertexData & data() const
Get vertex data.
int status() const
Get vertex status code.
shared_ptr< T > attribute(const string &name) const
Get attribute of type T.
Stores particle-related information.
GenEvent * m_event
Parent event.
const vector< GenParticlePtr > & particles_in()
Get list of incoming particles.
GenVertexData m_data
Vertex data.