Integration of OCCT 6.5.0 from SVN
[occt.git] / src / StepVisual / StepVisual_StyleContextSelect.cxx
1
2 #include <StepVisual_StyleContextSelect.ixx>
3 #include <Interface_Macros.hxx>
4
5 StepVisual_StyleContextSelect::StepVisual_StyleContextSelect () {  }
6
7 Standard_Integer StepVisual_StyleContextSelect::CaseNum(const Handle(Standard_Transient)& ent) const
8 {
9         if (ent.IsNull()) return 0;
10         if (ent->IsKind(STANDARD_TYPE(StepRepr_Representation))) return 1;
11         if (ent->IsKind(STANDARD_TYPE(StepRepr_RepresentationItem))) return 2;
12         if (ent->IsKind(STANDARD_TYPE(StepVisual_PresentationSet))) return 3;
13         return 0;
14 }
15
16 Handle(StepRepr_Representation) StepVisual_StyleContextSelect::Representation () const
17 {
18         return GetCasted(StepRepr_Representation,Value());
19 }
20
21 Handle(StepRepr_RepresentationItem) StepVisual_StyleContextSelect::RepresentationItem () const
22 {
23         return GetCasted(StepRepr_RepresentationItem,Value());
24 }
25
26 Handle(StepVisual_PresentationSet) StepVisual_StyleContextSelect::PresentationSet () const
27 {
28         return GetCasted(StepVisual_PresentationSet,Value());
29 }