CMS 3D CMS Logo

Public Member Functions

DDTrap Class Reference

Interface to a Trapezoid. More...

#include <DDSolid.h>

Inheritance diagram for DDTrap:
DDSolid DDBase< DDName, DDI::Solid * >

List of all members.

Public Member Functions

double alpha1 () const
 Angle with respect to the y axis from the centre of the side at y=-pDy1 to the centre at y=+pDy1 of the face at -pDz.
double alpha2 () const
 Angle with respect to the y axis from the centre of the side at y=-pDy2 to the centre at y=+pDy2 of the face at +pDz.
 DDTrap (const DDSolid &s)
double halfZ () const
 half of the z-Axis
double phi () const
 Azimuthal angle of the line joining the centres of the faces at -/+pDz.
double theta () const
 Polar angle of the line joining the centres of the faces at -/+pDz.
double x1 () const
 Half-length along x of the side at y=-pDy1 of the face at -pDz.
double x2 () const
 Half-length along x of the side at y=+pDy1 of the face at -pDz.
double x3 () const
 Half-length along x of the side at y=-pDy2 of the face at +pDz.
double x4 () const
 Half-length along x of the side at y=+pDy2 of the face at +pDz.
double y1 () const
 Half-length along y of the face at -pDz.
double y2 () const
 Half-length along y of the face at +pDz.

Detailed Description

Interface to a Trapezoid.

The definition (parameters, local frame) of the Trapezoid is the same than in Geant4.

Definition at line 115 of file DDSolid.h.


Constructor & Destructor Documentation

DDTrap::DDTrap ( const DDSolid s)

Definition at line 161 of file DDSolid.cc.

References ddtrap, DDName::name(), DDBase< N, C >::name(), DDName::ns(), and DDSolid::shape().

                                : DDSolid(s)
{
  if (s.shape() != ddtrap) {
    std::string ex  = "Solid [" + s.name().ns() + ":" + s.name().name() + "] is no DDTrap.\n";
    ex = ex + "Use a different solid interface!";
    throw DDException(ex);
  }
}

Member Function Documentation

double DDTrap::alpha1 ( ) const

Angle with respect to the y axis from the centre of the side at y=-pDy1 to the centre at y=+pDy1 of the face at -pDz.

Definition at line 182 of file DDSolid.cc.

References DDBase< DDName, DDI::Solid * >::rep().

Referenced by SolidsForOnline::beginRun(), DDDividedTrdZ::checkParametersValidity(), DDDividedTrdX::checkParametersValidity(), DDDividedTrdY::checkParametersValidity(), and DDCoreToDDXMLOutput::solid().

{ return rep().parameters()[6]; }
double DDTrap::alpha2 ( ) const

Angle with respect to the y axis from the centre of the side at y=-pDy2 to the centre at y=+pDy2 of the face at +pDz.

Definition at line 190 of file DDSolid.cc.

References DDBase< DDName, DDI::Solid * >::rep().

Referenced by SolidsForOnline::beginRun(), DDDividedTrdZ::checkParametersValidity(), DDDividedTrdX::checkParametersValidity(), DDDividedTrdY::checkParametersValidity(), and DDCoreToDDXMLOutput::solid().

{ return rep().parameters()[10]; }
double DDTrap::halfZ ( ) const
double DDTrap::phi ( ) const

Azimuthal angle of the line joining the centres of the faces at -/+pDz.

Definition at line 174 of file DDSolid.cc.

References DDBase< DDName, DDI::Solid * >::rep().

Referenced by SolidsForOnline::beginRun(), DDDividedTrdZ::checkParametersValidity(), DDDividedTrdX::checkParametersValidity(), DDDividedTrdY::checkParametersValidity(), and DDCoreToDDXMLOutput::solid().

{ return rep().parameters()[2]; }
double DDTrap::theta ( ) const

Polar angle of the line joining the centres of the faces at -/+pDz.

Definition at line 172 of file DDSolid.cc.

References DDBase< DDName, DDI::Solid * >::rep().

Referenced by SolidsForOnline::beginRun(), DDDividedTrdZ::checkParametersValidity(), DDDividedTrdX::checkParametersValidity(), DDDividedTrdY::checkParametersValidity(), and DDCoreToDDXMLOutput::solid().

{ return rep().parameters()[1]; }
double DDTrap::x1 ( ) const
double DDTrap::x2 ( ) const

Half-length along x of the side at y=+pDy1 of the face at -pDz.

Definition at line 180 of file DDSolid.cc.

References DDBase< DDName, DDI::Solid * >::rep().

Referenced by SolidsForOnline::beginRun(), DDDividedTrdX::checkParametersValidity(), HcalNumberingFromDDD::loadGeometry(), DDDividedTrdZ::makeDDLogicalPart(), DDDividedTrdY::makeDDLogicalPart(), and DDCoreToDDXMLOutput::solid().

{ return rep().parameters()[5]; }
double DDTrap::x3 ( ) const

Half-length along x of the side at y=-pDy2 of the face at +pDz.

Definition at line 186 of file DDSolid.cc.

References DDBase< DDName, DDI::Solid * >::rep().

Referenced by SolidsForOnline::beginRun(), DDDividedTrdX::checkParametersValidity(), HcalNumberingFromDDD::loadGeometry(), DDDividedTrdY::makeDDLogicalPart(), and DDCoreToDDXMLOutput::solid().

{ return rep().parameters()[8]; }
double DDTrap::x4 ( ) const

Half-length along x of the side at y=+pDy2 of the face at +pDz.

Definition at line 188 of file DDSolid.cc.

References DDBase< DDName, DDI::Solid * >::rep().

Referenced by SolidsForOnline::beginRun(), DDDividedTrdX::checkParametersValidity(), HcalNumberingFromDDD::loadGeometry(), DDDividedTrdY::makeDDLogicalPart(), and DDCoreToDDXMLOutput::solid().

{ return rep().parameters()[9]; }
double DDTrap::y1 ( ) const
double DDTrap::y2 ( ) const