ATLAS Offline Software
Static Public Member Functions | List of all members
GeoDBUtils Class Reference

Ensure that the extensions for the Vector3D are properly loaded. More...

#include <GeoDBUtils.h>

Collaboration diagram for GeoDBUtils:

Static Public Member Functions

static const IRDBRecordgetTransformRecord (IRDBRecordset_ptr positionRecSet, const std::string &key)
 
static GeoTrf::Transform3D getTransform (const IRDBRecord *currentRec)
 

Detailed Description

Ensure that the extensions for the Vector3D are properly loaded.

Definition at line 19 of file GeoDBUtils.h.

Member Function Documentation

◆ getTransform()

static GeoTrf::Transform3D GeoDBUtils::getTransform ( const IRDBRecord currentRec)
inlinestatic

Definition at line 33 of file GeoDBUtils.h.

33  {
34  double x = currentRec->getDouble("TRANSX")*Gaudi::Units::mm;
35  double y = currentRec->getDouble("TRANSY")*Gaudi::Units::mm;
36  double z = currentRec->getDouble("TRANSZ")*Gaudi::Units::mm;
37  double theta = currentRec->getDouble("THETA")*Gaudi::Units::rad;
38  double phi = currentRec->getDouble("PHI")*Gaudi::Units::rad;
39  double rotationAngle = currentRec->getDouble("ROTATIONANGLE")*Gaudi::Units::rad;
40 
42  return GeoTrf::Translate3D(x,y,z)*GeoTrf::Rotate3D(rotationAngle,axis);
43  }

◆ getTransformRecord()

static const IRDBRecord* GeoDBUtils::getTransformRecord ( IRDBRecordset_ptr  positionRecSet,
const std::string &  key 
)
inlinestatic

Definition at line 23 of file GeoDBUtils.h.

23  {
24  for (unsigned int s=0;s<positionRecSet->size(); s++) {
25  const IRDBRecord *currentRec= (*positionRecSet)[s];
26  if (key == currentRec->getString("NAME")) {
27  return currentRec;
28  }
29  }
30  return NULL;
31  }

The documentation for this class was generated from the following file:
python.SystemOfUnits.s
int s
Definition: SystemOfUnits.py:131
phi
Scalar phi() const
phi method
Definition: AmgMatrixBasePlugin.h:64
IRDBRecord::getString
virtual const std::string & getString(const std::string &fieldName) const =0
Get string field value.
theta
Scalar theta() const
theta method
Definition: AmgMatrixBasePlugin.h:71
yodamerge_tmp.axis
list axis
Definition: yodamerge_tmp.py:241
drawFromPickle.cos
cos
Definition: drawFromPickle.py:36
x
#define x
z
#define z
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
python.SystemOfUnits.mm
int mm
Definition: SystemOfUnits.py:83
y
#define y
IRDBRecord
IRDBRecord is one record in the IRDBRecordset object.
Definition: IRDBRecord.h:27
IRDBRecord::getDouble
virtual double getDouble(const std::string &fieldName) const =0
Get double field value.
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
python.SystemOfUnits.rad
int rad
Definition: SystemOfUnits.py:111
mapkey::key
key
Definition: TElectronEfficiencyCorrectionTool.cxx:37