CMS 3D CMS Logo

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

Relative position of a child-volume inside a parent-volume. More...

#include <DDPosData.h>

Public Member Functions

 DDPosData (const DDTranslation &t, const DDRotation &r, int c, const DDDivision *d=NULL)
 Creates a new relative position. More...
 
const DDDivisiondiv () const
 
const DDDivisiondivision () const
 
const DDRotationMatrixrot () const
 
const DDRotationMatrixrotation () const
 
const DDTranslationtrans () const
 
const DDTranslationtranslation () const
 

Public Attributes

int copyno_
 
const DDDivisiondiv_
 
void * replication_
 
DDRotation rot_
 
DDTranslation trans_
 

Private Member Functions

 DDPosData ()
 
DDPosDataoperator= (const DDPosData &)
 

Detailed Description

Relative position of a child-volume inside a parent-volume.

simple struct to collect information concerning the relative position of a child inside its parent.

replication is currently unused!

Definition at line 16 of file DDPosData.h.

Constructor & Destructor Documentation

DDPosData::DDPosData ( const DDTranslation t,
const DDRotation r,
int  c,
const DDDivision d = NULL 
)
inline

Creates a new relative position.

  • t relative translation std::vector
  • r relative rotation matrix
  • c copy number

Users normally don't create DDPosData themselves. They get read access to relative positionings via DDPosData in DDCompactView.

Definition at line 26 of file DDPosData.h.

27  : trans_(t), rot_(r), replication_(0), copyno_(c), div_(d)
28  {
29  //if (!rot_.rotation()) throw DDException("rotation not defined: [" + rot_.ns() + ":" + rot_.name() +"]" );
30  }
const DDDivision * div_
Definition: DDPosData.h:53
int copyno_
Definition: DDPosData.h:52
DDTranslation trans_
Definition: DDPosData.h:47
void * replication_
Definition: DDPosData.h:51
DDRotation rot_
Definition: DDPosData.h:49
DDPosData::DDPosData ( )
private

Member Function Documentation

const DDDivision& DDPosData::div ( ) const
inline

Definition at line 43 of file DDPosData.h.

References div_.

43 { return *div_; }
const DDDivision * div_
Definition: DDPosData.h:53
const DDDivision& DDPosData::division ( ) const
inline

Definition at line 44 of file DDPosData.h.

References div_.

44 { return *div_; }
const DDDivision * div_
Definition: DDPosData.h:53
DDPosData& DDPosData::operator= ( const DDPosData )
private
const DDRotationMatrix& DDPosData::rot ( ) const
inline

Definition at line 41 of file DDPosData.h.

References rot_, and DDRotation::rotation().

Referenced by DDExpandedView::firstChild(), and DDExpandedView::nextSibling().

41 { return *(rot_.rotation()); }
const DDRotationMatrix * rotation() const
Returns the read-only rotation-matrix.
Definition: DDTransform.h:90
DDRotation rot_
Definition: DDPosData.h:49
const DDRotationMatrix& DDPosData::rotation ( void  ) const
inline

Definition at line 40 of file DDPosData.h.

References rot_, and DDRotation::rotation().

40 { return *(rot_.rotation()); }
const DDRotationMatrix * rotation() const
Returns the read-only rotation-matrix.
Definition: DDTransform.h:90
DDRotation rot_
Definition: DDPosData.h:49
const DDTranslation& DDPosData::trans ( ) const
inline

Definition at line 38 of file DDPosData.h.

References trans_.

38 { return trans_; }
DDTranslation trans_
Definition: DDPosData.h:47
const DDTranslation& DDPosData::translation ( void  ) const
inline

Definition at line 37 of file DDPosData.h.

References trans_.

Referenced by DDCoreToDDXMLOutput::position().

37 { return trans_; }
DDTranslation trans_
Definition: DDPosData.h:47

Member Data Documentation

int DDPosData::copyno_

copy number

Definition at line 52 of file DDPosData.h.

Referenced by DDExpandedNode::copyno(), DDExpandedNode::operator==(), and DDCoreToDDXMLOutput::position().

const DDDivision* DDPosData::div_

provides original division that created this pos

Definition at line 53 of file DDPosData.h.

Referenced by div(), and division().

void* DDPosData::replication_

currently not used!

Definition at line 51 of file DDPosData.h.

DDRotation DDPosData::rot_

relative rotation matrix

Definition at line 49 of file DDPosData.h.

Referenced by DDCheckPD(), DDCoreToDDXMLOutput::position(), rot(), and rotation().

DDTranslation DDPosData::trans_

relative translation std::vector

Definition at line 47 of file DDPosData.h.

Referenced by DDExpandedView::firstChild(), trans(), and translation().