Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 12:54:57

0001 #include "DetectorDescription/Core/interface/DDLogicalPart.h"
0002 #include "DetectorDescription/Core/interface/DDName.h"
0003 #include "DetectorDescription/Core/interface/DDRoot.h"
0004 #include "FWCore/MessageLogger/interface/MessageLogger.h"
0005 
0006 DDRoot::DDRoot() {}
0007 
0008 DDRoot::~DDRoot() {}
0009 
0010 void DDRoot::set(const DDName& name) { root_ = DDLogicalPart(name); }
0011 
0012 void DDRoot::set(const DDLogicalPart& root) { root_ = root; }
0013 
0014 /**
0015   To find out, whether the root was already defined or not:
0016   \code
0017     DDLogicalPart root;
0018     if(root=DDRoot::instance().root()) { // ok, root was already defined
0019       // so something here ...
0020     }
0021     else { // root has not been defined yet!
0022       // do something else
0023     }      
0024    \endcode 
0025 */
0026 DDLogicalPart DDRoot::root() const { return root_; }