CMS 3D CMS Logo

LogicalPart.h
Go to the documentation of this file.
1 #ifndef DDI_LogicalPart_h
2 #define DDI_LogicalPart_h
3 
4 #include <iostream>
5 #include <map>
6 #include <utility>
7 #include <vector>
8 
14 
15 class DDPartSelection;
16 
17 namespace DDI {
18  class LogicalPart {
19  public:
21  const DDMaterial &material() const;
22  const DDSolid &solid() const;
24  std::vector<const DDsvalues_type *> specifics() const;
25  void specificsV(std::vector<const DDsvalues_type *> &result) const;
27  void mergedSpecificsV(DDsvalues_type &res) const;
28  void addSpecifics(const std::pair<const DDPartSelection *, const DDsvalues_type *> &);
29  void removeSpecifics(const std::pair<const DDPartSelection *, const DDsvalues_type *> &);
30  const std::vector<std::pair<const DDPartSelection *, const DDsvalues_type *> > &attachedSpecifics() const {
31  return specifics_;
32  }
33  bool hasDDValue(const DDValue &) const;
34  //const std::vector<DDPartSelection*> & partSelections(const DDValue &) const;
35  void stream(std::ostream &);
36 
37  private:
41 
42  std::map<DDValue, std::vector<DDPartSelection *> > valToParsel_;
43  std::vector<std::pair<const DDPartSelection *, const DDsvalues_type *> > specifics_;
44  std::vector<bool> hasDDValue_;
45  };
46 } // namespace DDI
47 #endif
DDI::LogicalPart::solid
const DDSolid & solid() const
Definition: LogicalPart.cc:16
DDI
Definition: DDCompactView.h:24
DDI::LogicalPart::solid_
DDSolid solid_
Definition: LogicalPart.h:39
DDI::LogicalPart::mergedSpecificsV
void mergedSpecificsV(DDsvalues_type &res) const
Definition: LogicalPart.cc:78
DDI::LogicalPart::hasDDValue_
std::vector< bool > hasDDValue_
Definition: LogicalPart.h:44
DDPartSelection
Definition: DDPartSelection.h:37
DDEnums.h
DDI::LogicalPart::specificsV
void specificsV(std::vector< const DDsvalues_type * > &result) const
Definition: LogicalPart.cc:63
DDI::LogicalPart::material
const DDMaterial & material() const
Definition: LogicalPart.cc:14
DDI::LogicalPart::LogicalPart
LogicalPart(const DDMaterial &, const DDSolid &, DDEnums::Category=DDEnums::unspecified)
Definition: LogicalPart.cc:11
DDI::LogicalPart::category
DDEnums::Category category() const
Definition: LogicalPart.cc:18
DDMaterial
DDMaterial is used to define and access material information.
Definition: DDMaterial.h:45
DDI::LogicalPart::hasDDValue
bool hasDDValue(const DDValue &) const
Definition: LogicalPart.cc:42
DDI::LogicalPart::material_
DDMaterial material_
Definition: LogicalPart.h:38
DDSolid.h
DDValue.h
DDEnums::Category
Category
Definition: DDEnums.h:7
DDMaterial.h
DDI::LogicalPart::specifics_
std::vector< std::pair< const DDPartSelection *, const DDsvalues_type * > > specifics_
Definition: LogicalPart.h:43
DDEnums::unspecified
Definition: DDEnums.h:7
res
Definition: Electron.h:6
DDI::LogicalPart::stream
void stream(std::ostream &)
Definition: LogicalPart.cc:20
DDValue
Definition: DDValue.h:21
DDI::LogicalPart::cat_
DDEnums::Category cat_
Definition: LogicalPart.h:40
DDSolid
A DDSolid represents the shape of a part.
Definition: DDSolid.h:39
DDsvalues.h
DDI::LogicalPart::mergedSpecifics
DDsvalues_type mergedSpecifics() const
Definition: LogicalPart.cc:72
DDI::LogicalPart
Definition: LogicalPart.h:18
DDI::LogicalPart::valToParsel_
std::map< DDValue, std::vector< DDPartSelection * > > valToParsel_
Definition: LogicalPart.h:42
mps_fire.result
result
Definition: mps_fire.py:303
DDsvalues_type
std::vector< std::pair< unsigned int, DDValue > > DDsvalues_type
Definition: DDsvalues.h:12
DDI::LogicalPart::specifics
std::vector< const DDsvalues_type * > specifics() const
Definition: LogicalPart.cc:57
DDI::LogicalPart::removeSpecifics
void removeSpecifics(const std::pair< const DDPartSelection *, const DDsvalues_type * > &)
Definition: LogicalPart.cc:51
DDI::LogicalPart::attachedSpecifics
const std::vector< std::pair< const DDPartSelection *, const DDsvalues_type * > > & attachedSpecifics() const
Definition: LogicalPart.h:30
DDI::LogicalPart::addSpecifics
void addSpecifics(const std::pair< const DDPartSelection *, const DDsvalues_type * > &)
Definition: LogicalPart.cc:24