CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
GsfCombinedMaterialEffectsUpdator Class Reference

#include <GsfCombinedMaterialEffectsUpdator.h>

Inheritance diagram for GsfCombinedMaterialEffectsUpdator:
GsfMaterialEffectsUpdator

Public Member Functions

virtual
GsfCombinedMaterialEffectsUpdator
clone () const
 
virtual void compute (const TrajectoryStateOnSurface &, const PropagationDirection, Effect[]) const
 
 GsfCombinedMaterialEffectsUpdator (GsfMaterialEffectsUpdator &msUpdator, GsfMaterialEffectsUpdator &elUpdator)
 Constructor from multiple scattering and energy loss updator. More...
 
- Public Member Functions inherited from GsfMaterialEffectsUpdator
 GsfMaterialEffectsUpdator (float mass, uint32_t is)
 
float mass () const
 
size_t size () const
 
virtual TrajectoryStateOnSurface updateState (const TrajectoryStateOnSurface &TSoS, const PropagationDirection propDir) const
 
virtual ~GsfMaterialEffectsUpdator ()
 

Private Attributes

DeepCopyPointerByClone
< GsfMaterialEffectsUpdator
theELUpdator
 
DeepCopyPointerByClone
< GsfMaterialEffectsUpdator
theMSUpdator
 

Additional Inherited Members

- Public Types inherited from GsfMaterialEffectsUpdator
typedef materialEffect::Covariance Covariance
 
typedef materialEffect::CovIndex CovIndex
 
typedef materialEffect::Effect Effect
 
- Protected Member Functions inherited from GsfMaterialEffectsUpdator
void resize (size_t is)
 

Detailed Description

Combines two GsfMaterialEffectsUpdators (for multiple scattering and energy loss).

Definition at line 10 of file GsfCombinedMaterialEffectsUpdator.h.

Constructor & Destructor Documentation

GsfCombinedMaterialEffectsUpdator::GsfCombinedMaterialEffectsUpdator ( GsfMaterialEffectsUpdator msUpdator,
GsfMaterialEffectsUpdator elUpdator 
)

Constructor from multiple scattering and energy loss updator.

Definition at line 6 of file GsfCombinedMaterialEffectsUpdator.cc.

Referenced by clone().

7  :
8  GsfMaterialEffectsUpdator(msUpdator.mass(),msUpdator.size()*elUpdator.size()),
9  theMSUpdator(msUpdator.clone()),
10  theELUpdator(elUpdator.clone()) {}
GsfMaterialEffectsUpdator(float mass, uint32_t is)
virtual GsfMaterialEffectsUpdator * clone() const =0
DeepCopyPointerByClone< GsfMaterialEffectsUpdator > theMSUpdator
DeepCopyPointerByClone< GsfMaterialEffectsUpdator > theELUpdator

Member Function Documentation

virtual GsfCombinedMaterialEffectsUpdator* GsfCombinedMaterialEffectsUpdator::clone ( void  ) const
inlinevirtual

Implements GsfMaterialEffectsUpdator.

Definition at line 13 of file GsfCombinedMaterialEffectsUpdator.h.

References GsfCombinedMaterialEffectsUpdator().

14  {
15  return new GsfCombinedMaterialEffectsUpdator(*this);
16  }
GsfCombinedMaterialEffectsUpdator(GsfMaterialEffectsUpdator &msUpdator, GsfMaterialEffectsUpdator &elUpdator)
Constructor from multiple scattering and energy loss updator.
void GsfCombinedMaterialEffectsUpdator::compute ( const TrajectoryStateOnSurface TSoS,
const PropagationDirection  propDir,
Effect  effects[] 
) const
virtual

Implements GsfMaterialEffectsUpdator.

Definition at line 16 of file GsfCombinedMaterialEffectsUpdator.cc.

References materialEffect::Effect::combine(), GsfMaterialEffectsUpdator::compute(), ProxyBase11< T >::data(), roll_playback::k, GsfMaterialEffectsUpdator::size(), theELUpdator, and theMSUpdator.

18 {
19  #if __clang__
20  std::vector<Effect> msEffects(theMSUpdator->size());
21  theMSUpdator->compute(TSoS,propDir,msEffects.data());
22  std::vector<Effect> elEffects(theELUpdator->size());
23  theELUpdator->compute(TSoS,propDir,elEffects.data());
24  #else
25  Effect msEffects[theMSUpdator->size()];
26  theMSUpdator->compute(TSoS,propDir,msEffects);
27  Effect elEffects[theELUpdator->size()];
28  theELUpdator->compute(TSoS,propDir,elEffects);
29  #endif
30 
31  //
32  // combine the two multi-updates
33  //
34  uint32_t k=0;
35  for ( auto const & mse : msEffects )
36  for ( auto const & ele : elEffects)
37  effects[k++].combine(mse,ele);
38  assert(k==size());
39 }
const T & data() const
Definition: ProxyBase11.h:66
virtual void compute(const TrajectoryStateOnSurface &, const PropagationDirection, Effect effects[]) const =0
DeepCopyPointerByClone< GsfMaterialEffectsUpdator > theMSUpdator
DeepCopyPointerByClone< GsfMaterialEffectsUpdator > theELUpdator

Member Data Documentation

DeepCopyPointerByClone<GsfMaterialEffectsUpdator> GsfCombinedMaterialEffectsUpdator::theELUpdator
private

Definition at line 30 of file GsfCombinedMaterialEffectsUpdator.h.

Referenced by compute().

DeepCopyPointerByClone<GsfMaterialEffectsUpdator> GsfCombinedMaterialEffectsUpdator::theMSUpdator
private

Definition at line 29 of file GsfCombinedMaterialEffectsUpdator.h.

Referenced by compute().