CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
egHLT::ParticlePair< T > Struct Template Reference

#include <EgHLTParticlePair.h>

Public Member Functions

float mass () const
 
 ParticlePair (const T &particle1, const T &particle2)
 
 ~ParticlePair ()=default
 

Public Attributes

const Tpart1
 
const Tpart2
 

Detailed Description

template<class T>
struct egHLT::ParticlePair< T >

Definition at line 8 of file EgHLTParticlePair.h.

Constructor & Destructor Documentation

◆ ParticlePair()

template<class T >
egHLT::ParticlePair< T >::ParticlePair ( const T particle1,
const T particle2 
)
inline

Definition at line 12 of file EgHLTParticlePair.h.

12 : part1(particle1), part2(particle2) {}

◆ ~ParticlePair()

template<class T >
egHLT::ParticlePair< T >::~ParticlePair ( )
default

Member Function Documentation

◆ mass()

template<class T >
float egHLT::ParticlePair< T >::mass ( ) const
inline

Definition at line 15 of file EgHLTParticlePair.h.

References mag(), egHLT::ParticlePair< T >::part1, and egHLT::ParticlePair< T >::part2.

Referenced by Particle.Particle::__str__(), and DiObject.DiMuon::__str__().

15 { return (part1.p4() + part2.p4()).mag(); }
T mag() const
The vector magnitude. Equivalent to sqrt(vec.mag2())

Member Data Documentation

◆ part1

template<class T >
const T& egHLT::ParticlePair< T >::part1

Definition at line 9 of file EgHLTParticlePair.h.

Referenced by egHLT::ParticlePair< T >::mass().

◆ part2

template<class T >
const T& egHLT::ParticlePair< T >::part2

Definition at line 10 of file EgHLTParticlePair.h.

Referenced by egHLT::ParticlePair< T >::mass().