CMS 3D CMS Logo

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

#include <DDDivision.h>

Inheritance diagram for DDDivision:
DDBase< DDName, DDI::Division * >

Public Member Functions

DDAxes axis () const
 
 DDDivision ()
 The default constructor provides an uninitialzed reference object. More...
 
 DDDivision (const DDName &name)
 Creates a refernce object referring to the appropriate XML specification. More...
 
 DDDivision (const DDName &name, const DDLogicalPart &parent, const DDAxes axis, const int nReplicas, const double width, const double offset)
 Registers (creates) a reference object representing a Division. More...
 
 DDDivision (const DDName &name, const DDLogicalPart &parent, const DDAxes axis, const int nReplicas, const double offset)
 Registers (creates) a reference object representing a Division. More...
 
 DDDivision (const DDName &name, const DDLogicalPart &parent, const DDAxes axis, const double width, const double offset)
 Registers (creates) a reference object representing a Division. More...
 
int nReplicas () const
 
double offset () const
 
const DDLogicalPartparent () const
 
double width () const
 
- Public Member Functions inherited from DDBase< DDName, DDI::Division * >
 DDBase ()
 
const DDNameddname () const
 
def_type isDefined () const
 
bool isValid () const
 true, if the wrapped pointer is valid More...
 
const DDNamename () const
 
 operator bool () const
 
bool operator< (const DDBase &b) const
 
bool operator== (const DDBase &b) const
 
bool operator> (const DDBase &b) const
 
const DDI::rep_traits< DDName,
DDI::Division * >::reference 
rep () const
 
DDI::rep_traits< DDName,
DDI::Division * >::reference 
rep ()
 
std::string toString () const
 
const DDI::rep_traits< DDName,
DDI::Division * >::reference 
val () const
 
const DDI::rep_traits< DDName,
DDI::Division * >::reference 
val ()
 
virtual ~DDBase ()
 

Friends

std::ostream & operator<< (std::ostream &, const DDDivision &)
 

Additional Inherited Members

- Public Types inherited from DDBase< DDName, DDI::Division * >
typedef std::pair< const
DDName *, bool > 
def_type
 
typedef DDI::Divisionpimpl_type
 
typedef DDI::rep_type< DDName,
pimpl_type > * 
prep_type
 
typedef DDI::Singleton
< DDI::Store< DDName,
DDI::Division * > > 
StoreT
 
- Static Public Member Functions inherited from DDBase< DDName, DDI::Division * >
static DDI::Store< DDName,
DDI::Division * >::iterator 
begin ()
 
static void clear ()
 
static DDI::Store< DDName,
DDI::Division * >::iterator 
end ()
 
static size_t size ()
 
- Protected Attributes inherited from DDBase< DDName, DDI::Division * >
prep_type prep_
 

Detailed Description

Definition at line 71 of file DDDivision.h.

Constructor & Destructor Documentation

DDDivision::DDDivision ( )

The default constructor provides an uninitialzed reference object.

Definition at line 42 of file DDDivision.cc.

DDDivision::DDDivision ( const DDName name)

Creates a refernce object referring to the appropriate XML specification.

Definition at line 45 of file DDDivision.cc.

References DDI::Singleton< I >::instance(), and DDBase< DDName, DDI::Division * >::prep_.

46 {
47  prep_ = StoreT::instance().create(name);
48  // DD_NDC(name);
49 }
static value_type & instance()
DDDivision::DDDivision ( const DDName name,
const DDLogicalPart parent,
const DDAxes  axis,
const int  nReplicas,
const double  width,
const double  offset 
)

Registers (creates) a reference object representing a Division.

... Constructor with number of divisions and width

Definition at line 51 of file DDDivision.cc.

References DCOUT, DDI::Singleton< I >::instance(), DDAxesNames::name(), DDBase< N, C >::name(), offset(), and DDBase< DDName, DDI::Division * >::prep_.

57 {
58  DCOUT('C', "create Division name=" << name << " parent=" << parent.name() << " axis=" << DDAxesNames::name(axis) << " nReplicas=" << nReplicas << " width=" << width << " offset=" << offset);
59  prep_ = StoreT::instance().create(name, new Division(parent, axis, nReplicas, width, offset));
60  // DD_NDC(name);
61 }
const N & name() const
Definition: DDBase.h:82
int nReplicas() const
Definition: DDDivision.cc:90
double offset() const
Definition: DDDivision.cc:100
static value_type & instance()
DDAxes axis() const
Definition: DDDivision.cc:85
double width() const
Definition: DDDivision.cc:95
static const std::string name(const DDAxes &s)
Definition: DDAxes.cc:37
#define DCOUT(M_v_Y, M_v_S)
Definition: DDdebug.h:53
DDDivision::DDDivision ( const DDName name,
const DDLogicalPart parent,
const DDAxes  axis,
const int  nReplicas,
const double  offset 
)

Registers (creates) a reference object representing a Division.

... Constructor with number of divisions

Definition at line 63 of file DDDivision.cc.

References DCOUT, DDI::Singleton< I >::instance(), DDAxesNames::name(), DDBase< N, C >::name(), offset(), and DDBase< DDName, DDI::Division * >::prep_.

68 {
69  DCOUT('C', "create Division name=" << name << " parent=" << parent.name() << " axis=" << DDAxesNames::name(axis) << " nReplicas=" << nReplicas << " offset=" << offset);
70  prep_ = StoreT::instance().create(name, new Division(parent, axis, nReplicas, offset));
71  // DD_NDC(name);
72 }
const N & name() const
Definition: DDBase.h:82
int nReplicas() const
Definition: DDDivision.cc:90
double offset() const
Definition: DDDivision.cc:100
static value_type & instance()
DDAxes axis() const
Definition: DDDivision.cc:85
static const std::string name(const DDAxes &s)
Definition: DDAxes.cc:37
#define DCOUT(M_v_Y, M_v_S)
Definition: DDdebug.h:53
DDDivision::DDDivision ( const DDName name,
const DDLogicalPart parent,
const DDAxes  axis,
const double  width,
const double  offset 
)

Registers (creates) a reference object representing a Division.

... Constructor with width

Definition at line 74 of file DDDivision.cc.

References DCOUT, DDI::Singleton< I >::instance(), DDAxesNames::name(), DDBase< N, C >::name(), offset(), and DDBase< DDName, DDI::Division * >::prep_.

79 {
80  DCOUT('C', "create Division name=" << name << " parent=" << parent.name() << " axis=" << DDAxesNames::name(axis) << " width=" << width << " offset=" << offset);
81  prep_ = StoreT::instance().create(name, new Division(parent, axis, width, offset));
82  // DD_NDC(name);
83 }
const N & name() const
Definition: DDBase.h:82
double offset() const
Definition: DDDivision.cc:100
static value_type & instance()
DDAxes axis() const
Definition: DDDivision.cc:85
double width() const
Definition: DDDivision.cc:95
static const std::string name(const DDAxes &s)
Definition: DDAxes.cc:37
#define DCOUT(M_v_Y, M_v_S)
Definition: DDdebug.h:53

Member Function Documentation

DDAxes DDDivision::axis ( ) const
int DDDivision::nReplicas ( ) const
double DDDivision::offset ( ) const

Definition at line 100 of file DDDivision.cc.

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

Referenced by DDDividedGeometryObject::checkNDivAndWidth(), DDDividedGeometryObject::checkOffset(), DDDividedPolyconeRho::checkParametersValidity(), DDDividedPolyhedraRho::checkParametersValidity(), DDDividedPolyhedraPhi::checkParametersValidity(), DDDividedPolyconeZ::checkParametersValidity(), DDDividedPolyhedraZ::checkParametersValidity(), DDDividedBoxX::DDDividedBoxX(), DDDividedBoxY::DDDividedBoxY(), DDDividedBoxZ::DDDividedBoxZ(), DDDividedConsPhi::DDDividedConsPhi(), DDDividedConsRho::DDDividedConsRho(), DDDividedConsZ::DDDividedConsZ(), DDDividedPolyconePhi::DDDividedPolyconePhi(), DDDividedPolyconeRho::DDDividedPolyconeRho(), DDDividedPolyconeZ::DDDividedPolyconeZ(), DDDividedPolyhedraPhi::DDDividedPolyhedraPhi(), DDDividedPolyhedraRho::DDDividedPolyhedraRho(), DDDividedPolyhedraZ::DDDividedPolyhedraZ(), DDDividedTrdX::DDDividedTrdX(), DDDividedTrdY::DDDividedTrdY(), DDDividedTrdZ::DDDividedTrdZ(), DDDividedTubsPhi::DDDividedTubsPhi(), DDDividedTubsRho::DDDividedTubsRho(), DDDividedTubsZ::DDDividedTubsZ(), DDDivision(), DDDividedConsRho::makeDDLogicalPart(), DDDividedTubsRho::makeDDLogicalPart(), DDDividedPolyconeRho::makeDDLogicalPart(), DDDividedPolyhedraRho::makeDDLogicalPart(), DDDividedConsPhi::makeDDLogicalPart(), DDDividedTubsPhi::makeDDLogicalPart(), DDDividedPolyconePhi::makeDDLogicalPart(), DDDividedPolyhedraPhi::makeDDLogicalPart(), DDDividedConsZ::makeDDLogicalPart(), DDDividedTrdZ::makeDDLogicalPart(), DDDividedBoxX::makeDDTranslation(), DDDividedTrdX::makeDDTranslation(), DDDividedBoxY::makeDDTranslation(), DDDividedTrdY::makeDDTranslation(), DDDividedBoxZ::makeDDTranslation(), DDDividedTubsZ::makeDDTranslation(), DDDividedConsZ::makeDDTranslation(), DDDividedTrdZ::makeDDTranslation(), and DDDividedPolyhedraZ::makeDDTranslation().

101 {
102  return rep().offset();
103 }
const DDI::rep_traits< DDName, DDI::Division * >::reference rep() const
Definition: DDBase.h:89
const DDLogicalPart & DDDivision::parent ( ) const

Definition at line 105 of file DDDivision.cc.

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

Referenced by BeautifulSoup.PageElement::_invert(), Vispa.Gui.ConnectableWidget.ConnectableWidget::addMenuEntry(), Vispa.Views.LineDecayView.LineDecayContainer::applyFilter(), Vispa.Views.BoxDecayView.BoxDecayContainer::arrangeUsingRelations(), Vispa.Views.BoxDecayView.BoxDecayContainer::autolayoutAlgorithm(), Vispa.Gui.ZoomableScrollableWidgetOwner.ZoomableScrollableWidgetOwner::autosizeScrollArea(), Vispa.Views.BoxDecayView.BoxDecayContainer::autosizeScrollArea(), DDDividedGeometryObject::checkNDivAndWidth(), DDDividedGeometryObject::checkOffset(), DDDividedTrdX::checkParametersValidity(), DDDividedPolyhedraRho::checkParametersValidity(), DDDividedPolyconeRho::checkParametersValidity(), DDDividedTrdY::checkParametersValidity(), DDDividedPolyhedraPhi::checkParametersValidity(), DDDividedGeometryObject::checkParametersValidity(), DDDividedTrdZ::checkParametersValidity(), DDDividedPolyconeZ::checkParametersValidity(), DDDividedPolyhedraZ::checkParametersValidity(), Vispa.Gui.PortWidget.PortWidget::connectionPoint(), Vispa.Main.StartupScreen.StartupScreen::createDescriptionWidget(), Vispa.Views.BoxDecayView.BoxDecayContainer::dataAccessor(), Vispa.Views.LineDecayView.LineDecayContainer::dataAccessor(), Vispa.Views.LineDecayView.DecayLine::dataAccessor(), DDDividedBoxX::DDDividedBoxX(), DDDividedBoxY::DDDividedBoxY(), DDDividedBoxZ::DDDividedBoxZ(), DDDividedConsPhi::DDDividedConsPhi(), DDDividedConsRho::DDDividedConsRho(), DDDividedConsZ::DDDividedConsZ(), DDDividedPolyconePhi::DDDividedPolyconePhi(), DDDividedPolyconeRho::DDDividedPolyconeRho(), DDDividedPolyconeZ::DDDividedPolyconeZ(), DDDividedPolyhedraPhi::DDDividedPolyhedraPhi(), DDDividedPolyhedraRho::DDDividedPolyhedraRho(), DDDividedPolyhedraZ::DDDividedPolyhedraZ(), DDDividedTrdX::DDDividedTrdX(), DDDividedTrdY::DDDividedTrdY(), DDDividedTrdZ::DDDividedTrdZ(), DDDividedTubsPhi::DDDividedTubsPhi(), DDDividedTubsRho::DDDividedTubsRho(), DDDividedTubsZ::DDDividedTubsZ(), Vispa.Views.LineDecayView.LineDecayContainer::delete(), Vispa.Views.LineDecayView.DecayNode::delete(), Vispa.Views.LineDecayView.DecayLine::delete(), Vispa.Gui.VispaWidget.VispaWidget::delete(), Vispa.Gui.VispaWidget.VispaWidget::dragWidget(), DDDividedGeometryObject::execute(), Vispa.Share.ImageExporter.ImageExporter::exportImageDialog(), Vispa.Views.LineDecayView.DecayLine::extendedSize(), DDDividedTubsRho::getMaxParameter(), DDDividedConsRho::getMaxParameter(), DDDividedBoxX::getMaxParameter(), DDDividedTrdX::getMaxParameter(), DDDividedPolyhedraRho::getMaxParameter(), DDDividedPolyconeRho::getMaxParameter(), DDDividedConsPhi::getMaxParameter(), DDDividedTubsPhi::getMaxParameter(), DDDividedBoxY::getMaxParameter(), DDDividedTrdY::getMaxParameter(), DDDividedPolyconePhi::getMaxParameter(), DDDividedPolyhedraPhi::getMaxParameter(), DDDividedBoxZ::getMaxParameter(), DDDividedTubsZ::getMaxParameter(), DDDividedConsZ::getMaxParameter(), DDDividedTrdZ::getMaxParameter(), DDDividedPolyconeZ::getMaxParameter(), DDDividedPolyhedraZ::getMaxParameter(), Vispa.Gui.VispaWidget.VispaWidget::keyPressEvent(), Vispa.Gui.MenuWidget.MenuWidget::leaveEvent(), Vispa.Gui.ConnectableWidget.ConnectableWidget::leaveEvent(), DDDividedTubsRho::makeDDLogicalPart(), DDDividedConsRho::makeDDLogicalPart(), DDDividedTrdX::makeDDLogicalPart(), DDDividedBoxX::makeDDLogicalPart(), DDDividedGeometryObject::makeDDLogicalPart(), DDDividedPolyconeRho::makeDDLogicalPart(), DDDividedPolyhedraRho::makeDDLogicalPart(), DDDividedBoxY::makeDDLogicalPart(), DDDividedConsPhi::makeDDLogicalPart(), DDDividedTubsPhi::makeDDLogicalPart(), DDDividedTrdY::makeDDLogicalPart(), DDDividedPolyconePhi::makeDDLogicalPart(), DDDividedPolyhedraPhi::makeDDLogicalPart(), DDDividedBoxZ::makeDDLogicalPart(), DDDividedTubsZ::makeDDLogicalPart(), DDDividedConsZ::makeDDLogicalPart(), DDDividedTrdZ::makeDDLogicalPart(), DDDividedPolyconeZ::makeDDLogicalPart(), DDDividedPolyhedraZ::makeDDLogicalPart(), DDDividedConsPhi::makeDDRotation(), DDDividedTubsPhi::makeDDRotation(), DDDividedPolyconePhi::makeDDRotation(), DDDividedPolyhedraPhi::makeDDRotation(), DDDividedBoxX::makeDDTranslation(), DDDividedTrdX::makeDDTranslation(), DDDividedBoxY::makeDDTranslation(), DDDividedTrdY::makeDDTranslation(), DDDividedBoxZ::makeDDTranslation(), DDDividedConsZ::makeDDTranslation(), DDDividedTubsZ::makeDDTranslation(), DDDividedTrdZ::makeDDTranslation(), DDDividedPolyconeZ::makeDDTranslation(), DDDividedPolyhedraZ::makeDDTranslation(), DDLDivision::makeDivider(), Vispa.Gui.PortWidget.PortWidget::moduleParent(), Vispa.Gui.WidgetContainer.WidgetContainer::mouseDoubleClickEvent(), Vispa.Gui.VispaWidget.VispaWidget::mouseDoubleClickEvent(), Vispa.Gui.PortConnection.PointToPointConnection::mousePressEvent(), Vispa.Gui.VispaWidget.VispaWidget::mousePressEvent(), Vispa.Views.LineDecayView.ParticleWidget::mousePressEvent(), Vispa.Views.LineDecayView.DecayNode::move(), Vispa.Views.LineDecayView.LineDecayContainer::noDecorationsMode(), Vispa.Views.LineDecayView.LineDecayContainer::operationId(), Vispa.Views.LineDecayView.DecayLine::paint(), Vispa.Gui.VispaWidget.VispaWidget::paintEvent(), Vispa.Gui.ConnectableWidget.ConnectableWidget::positionizeMenuWidget(), Vispa.Views.LineDecayView.DecayLine::qtLineStyle(), Vispa.Views.WidgetView.WidgetView::restoreSelection(), Vispa.Views.WidgetView.WidgetView::select(), Vispa.Gui.PortConnection.PointToPointConnection::select(), Vispa.Gui.VispaWidget.VispaWidget::select(), Vispa.Views.LineDecayView.LineDecayContainer::select(), Vispa.Views.LineDecayView.LineDecayContainer::sizeHint(), Vispa.Views.LineDecayView.LineDecayContainer::tabController(), Vispa.Views.BoxDecayView.BoxDecayContainer::toggleCollapsed(), Vispa.Views.LineDecayView.DecayNode::unite(), Vispa.Views.PropertyView.PropertyView::valueChanged(), Vispa.Views.BoxDecayView.BoxDecayContainer::widgetByObject(), Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner::widgetDoubleClicked(), and Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner::widgetDragged().

106 {
107  return rep().parent();
108 }
const DDI::rep_traits< DDName, DDI::Division * >::reference rep() const
Definition: DDBase.h:89
double DDDivision::width ( ) const

Definition at line 95 of file DDDivision.cc.

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

Referenced by Vispa.Main.MainWindow.MainWindow::_saveIni(), Vispa.Gui.VispaWidget.VispaWidget::autosize(), Vispa.Gui.VispaWidget.VispaWidget::boundingRect(), DDDividedPolyconeZ::checkParametersValidity(), Vispa.Gui.VispaWidget.VispaWidget::contentRect(), DDDividedBoxX::DDDividedBoxX(), DDDividedBoxY::DDDividedBoxY(), DDDividedBoxZ::DDDividedBoxZ(), DDDividedConsPhi::DDDividedConsPhi(), DDDividedConsRho::DDDividedConsRho(), DDDividedConsZ::DDDividedConsZ(), DDDividedGeometryObject::DDDividedGeometryObject(), DDDividedPolyconePhi::DDDividedPolyconePhi(), DDDividedPolyconeRho::DDDividedPolyconeRho(), DDDividedPolyconeZ::DDDividedPolyconeZ(), DDDividedPolyhedraPhi::DDDividedPolyhedraPhi(), DDDividedPolyhedraRho::DDDividedPolyhedraRho(), DDDividedPolyhedraZ::DDDividedPolyhedraZ(), DDDividedTrdX::DDDividedTrdX(), DDDividedTrdY::DDDividedTrdY(), DDDividedTrdZ::DDDividedTrdZ(), DDDividedTubsPhi::DDDividedTubsPhi(), DDDividedTubsRho::DDDividedTubsRho(), DDDividedTubsZ::DDDividedTubsZ(), Vispa.Gui.VispaWidget.VispaWidget::defineArrowBackgroundShape(), Vispa.Gui.VispaWidget.VispaWidget::defineCircleBackgroundShape(), Vispa.Gui.VispaWidget.VispaWidget::defineRoundRectBackgroundShape(), Vispa.Gui.VispaWidget.VispaWidget::drawHeaderBackground(), Vispa.Gui.ConnectableWidget.ConnectableWidget::drawPortNames(), Vispa.Gui.VispaWidget.VispaWidget::imageRectF(), Vispa.Gui.ConnectableWidget.ConnectableWidget::positionizeMenuWidget(), Vispa.Views.PropertyView.PropertyView::resizeEvent(), Vispa.Views.PropertyView.PropertyView::sectionResized(), Vispa.Gui.VispaWidget.VispaWidget::setZoom(), and Vispa.Main.MainWindow.MainWindow::updateStartupScreenGeometry().

96 {
97  return rep().width();
98 }
const DDI::rep_traits< DDName, DDI::Division * >::reference rep() const
Definition: DDBase.h:89

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  os,
const DDDivision div 
)
friend

Definition at line 24 of file DDDivision.cc.

25 {
27  if (defined.first) {
28  os << *(defined.first) << " ";
29  if (defined.second) {
30  div.rep().stream(os);
31  }
32  else {
33  os << "* division not defined * ";
34  }
35  }
36  else {
37  os << "* division not declared * ";
38  }
39  return os;
40 }
const DDI::rep_traits< N, C >::reference rep() const
Definition: DDBase.h:89
def_type isDefined() const
Definition: DDBase.h:115
std::pair< const N *, bool > def_type
Definition: DDBase.h:77