69 friend std::ostream&
operator<<( std::ostream& ostr,
const Flow& f );
87 void print( std::ostream& ostr = std::cout )
const;
92 int num_indices = 2 )
const;
97 int code_index = 1,
int num_indices = 2 )
const;
106 int icode(
int code_index = 1 )
const;
123 bool erase(
int code_index );
143 int num_indices )
const;
147 std::vector<HepMC::GenParticle*>*
149 int code,
int code_index,
150 int num_indices )
const;
153 std::map<int,int> m_icode;
161 return m_particle_owner;
164 std::map<int,int>::const_iterator a = m_icode.find(code_index);
165 return a==m_icode.end() ? 0 : (*a).second;
168 m_icode[code_index] = code;
174 m_icode[flow_num] = size_t(
this);
178 inline int Flow::size()
const {
return (
int)m_icode.size(); }
182 return m_icode.erase( code_index )==0 ?
false : true ;
197 return (m_icode == a.m_icode);
200 return !( *
this == a );
207 m_icode = inflow.m_icode;
213 #endif // HEPMC_FLOW_H
Flow set_unique_icode(int code_index=1)
set unique flow code
void print(std::ostream &ostr=std::cout) const
print Flow information to ostr
bool operator!=(const Flow &a) const
inequality
iterator end()
end of flow pattern container
bool empty() const
return true if there is no flow container
std::map< int, int >::const_iterator const_iterator
const iterator for flow pattern container
bool operator==(const Flow &a) const
equality
Flow & operator=(const Flow &)
make a copy
std::vector< HepMC::GenParticle * > connected_partners(int code, int code_index=1, int num_indices=2) const
void swap(Flow &other)
swap
friend std::ostream & operator<<(std::ostream &ostr, const Flow &f)
for printing
iterator begin()
beginning of flow pattern container
Flow set_icode(int code_index, int code)
set flow code
int size() const
size of flow pattern container
const GenParticle * particle_owner() const
find particle owning this Flow
std::map< int, int >::iterator iterator
iterator for flow pattern container
std::vector< HepMC::GenParticle * > dangling_connected_partners(int code, int code_index=1, int num_indices=2) const
Flow(GenParticle *particle_owner=0)
default constructor
bool erase(int code_index)
empty flow pattern container
void clear()
clear flow patterns
int icode(int code_index=1) const
flow code
The GenParticle class contains information about generated particles.