Rev 120 | Rev 168 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
| Rev 120 | Rev 140 | ||
|---|---|---|---|
| Line 13... | Line 13... | ||
| 13 | Flow::Flow( GenParticle* particle_owner ) |
13 | Flow::Flow( GenParticle* particle_owner ) |
| 14 | : m_particle_owner(particle_owner) |
14 | : m_particle_owner(particle_owner) |
| 15 | {} |
15 | {} |
| 16 | 16 | ||
| 17 | Flow::Flow( const Flow& inflow ) : |
17 | Flow::Flow( const Flow& inflow ) : |
| 18 | m_particle_owner(inflow.m_particle_owner) |
18 | m_particle_owner(inflow.m_particle_owner), |
| - | 19 | m_icode(inflow.m_icode) |
|
| 19 | {
|
20 | {
|
| 20 | /// copies both the m_icode AND the m_particle_owner
|
21 | /// copies both the m_icode AND the m_particle_owner
|
| 21 | *this = inflow; |
- | |
| 22 | }
|
22 | }
|
| 23 | 23 | ||
| 24 | Flow::~Flow() { |
24 | Flow::~Flow() { |
| 25 | m_icode.clear(); |
25 | m_icode.clear(); |
| - | 26 | }
|
|
| - | 27 | ||
| - | 28 | void Flow::swap( Flow & other) |
|
| - | 29 | {
|
|
| - | 30 | std::swap( m_particle_owner, other.m_particle_owner ); |
|
| - | 31 | m_icode.swap( other.m_icode ); |
|
| 26 | }
|
32 | }
|
| 27 | 33 | ||
| 28 | void Flow::print( std::ostream& ostr ) const { |
34 | void Flow::print( std::ostream& ostr ) const { |
| 29 | ostr << "Flow(" << m_particle_owner << "): " << *this << std::endl; |
35 | ostr << "Flow(" << m_particle_owner << "): " << *this << std::endl; |
| 30 | }
|
36 | }
|