From 8a1c9b90ae9d9620740d812a098b9fb5bd067d6e Mon Sep 17 00:00:00 2001 From: Frank Gaede <frank.gaede@desy.de> Date: Wed, 9 Nov 2016 11:47:20 +0100 Subject: [PATCH] rm LayeredCalorimeterData::Layer.thickness add phi0 - add copy assignement to MaterialData --- DDRec/include/DDRec/DetectorData.h | 8 ++++---- DDRec/include/DDRec/Material.h | 14 +++++++++++++- 2 files changed, 17 insertions(+), 5 deletions(-) diff --git a/DDRec/include/DDRec/DetectorData.h b/DDRec/include/DDRec/DetectorData.h index 287b54ae9..8bf146dcd 100644 --- a/DDRec/include/DDRec/DetectorData.h +++ b/DDRec/include/DDRec/DetectorData.h @@ -389,7 +389,7 @@ namespace DD4hep { Layer() : distance(0), - thickness(0), + phi0(0), absorberThickness(0), inner_nRadiationLengths(0), inner_nInteractionLengths(0), @@ -405,10 +405,10 @@ namespace DD4hep { /// distance from Origin (or the z-axis) to the inner-most face of the layer double distance; - /// DEPRECATED: total thickness of the layer. Use inner/outer thicknesses instead - double thickness ; + /// phi0 of layer: potential rotation around normal to absorber plane, e.g. if layers are 'staggered' in phi in fwd. calos + double phi0 ; - /// DEPRECATED: thickness of the absorber part of the layer. Use instead number of X0, lambdaI in and out + /// thickness of the absorber part of the layer. Consider using inner/outer_nRadiationLengths and inner/outer_nInteractionLengths double absorberThickness ; ///Absorber material in front of sensitive element in the layer, units of radiation lengths diff --git a/DDRec/include/DDRec/Material.h b/DDRec/include/DDRec/Material.h index ecdd3abc8..077f7aa34 100644 --- a/DDRec/include/DDRec/Material.h +++ b/DDRec/include/DDRec/Material.h @@ -84,8 +84,20 @@ namespace DD4hep { _x0( m.radiationLength() ), _lambda( m.interactionLength() ) {} + /// copy assignement + MaterialData& operator=(const MaterialData& m){ + if ( this != &m ) { + _name = m._name ; + _Z = m._Z ; + _A = m._A ; + _rho = m._rho ; + _x0 = m._x0 ; + _lambda = m._lambda ; + } + return *this ; + } - /// assignment from Geometry::Material + /// assignment from Geometry::Material MaterialData& operator=(const IMaterial& m){ if ( this != &m ) { _name = m.name() ; -- GitLab