0024947: Redesign OCCT legacy type system -- automatic
[occt.git] / src / StepAP214 / StepAP214_AutoDesignGroupedItem.cxx
CommitLineData
973c2be1 1// Copyright (c) 1999-2014 OPEN CASCADE SAS
b311480e 2//
973c2be1 3// This file is part of Open CASCADE Technology software library.
b311480e 4//
d5f74e42 5// This library is free software; you can redistribute it and/or modify it under
6// the terms of the GNU Lesser General Public License version 2.1 as published
973c2be1 7// by the Free Software Foundation, with special exception defined in the file
8// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
9// distribution for complete text of the license and disclaimer of any warranty.
b311480e 10//
973c2be1 11// Alternatively, this file may be used under the terms of Open CASCADE
12// commercial license or contractual agreement.
7fd59977 13
14#include <StepAP214_AutoDesignGroupedItem.ixx>
15#include <Interface_Macros.hxx>
ec357c5c 16#include <StepShape_AdvancedBrepShapeRepresentation.hxx>
17#include <StepShape_CsgShapeRepresentation.hxx>
18#include <StepShape_FacetedBrepShapeRepresentation.hxx>
19#include <StepShape_GeometricallyBoundedSurfaceShapeRepresentation.hxx>
20#include <StepShape_GeometricallyBoundedWireframeShapeRepresentation.hxx>
21#include <StepShape_ManifoldSurfaceShapeRepresentation.hxx>
22#include <StepRepr_Representation.hxx>
23#include <StepRepr_RepresentationItem.hxx>
24#include <StepShape_ShapeRepresentation.hxx>
25#include <StepRepr_ShapeAspect.hxx>
26#include <StepVisual_TemplateInstance.hxx>
7fd59977 27
28StepAP214_AutoDesignGroupedItem::StepAP214_AutoDesignGroupedItem () { }
29
30Standard_Integer StepAP214_AutoDesignGroupedItem::CaseNum(const Handle(Standard_Transient)& ent) const
31{
32 if (ent.IsNull()) return 0;
33 if (ent->IsKind(STANDARD_TYPE(StepShape_AdvancedBrepShapeRepresentation))) return 1;
34 if (ent->IsKind(STANDARD_TYPE(StepShape_CsgShapeRepresentation))) return 2;
35 if (ent->IsKind(STANDARD_TYPE(StepShape_FacetedBrepShapeRepresentation))) return 3;
36 if (ent->IsKind(STANDARD_TYPE(StepShape_GeometricallyBoundedSurfaceShapeRepresentation))) return 4;
37 if (ent->IsKind(STANDARD_TYPE(StepShape_GeometricallyBoundedWireframeShapeRepresentation))) return 5;
38 if (ent->IsKind(STANDARD_TYPE(StepShape_ManifoldSurfaceShapeRepresentation))) return 6;
39 if (ent->IsKind(STANDARD_TYPE(StepRepr_Representation))) return 7;
40 if (ent->IsKind(STANDARD_TYPE(StepRepr_RepresentationItem))) return 8;
41 if (ent->IsKind(STANDARD_TYPE(StepShape_ShapeRepresentation))) return 9;
42 if (ent->IsKind(STANDARD_TYPE(StepRepr_ShapeAspect))) return 10;
43 if (ent->IsKind(STANDARD_TYPE(StepVisual_TemplateInstance))) return 11;
44 return 0;
45}
46
47Handle(StepShape_AdvancedBrepShapeRepresentation) StepAP214_AutoDesignGroupedItem::AdvancedBrepShapeRepresentation () const
48{
49 return GetCasted(StepShape_AdvancedBrepShapeRepresentation,Value());
50}
51
52Handle(StepShape_CsgShapeRepresentation) StepAP214_AutoDesignGroupedItem::CsgShapeRepresentation () const
53{
54 return GetCasted(StepShape_CsgShapeRepresentation,Value());
55}
56
57Handle(StepShape_FacetedBrepShapeRepresentation) StepAP214_AutoDesignGroupedItem::FacetedBrepShapeRepresentation () const
58{
59 return GetCasted(StepShape_FacetedBrepShapeRepresentation,Value());
60}
61
62Handle(StepShape_GeometricallyBoundedSurfaceShapeRepresentation) StepAP214_AutoDesignGroupedItem::GeometricallyBoundedSurfaceShapeRepresentation () const
63{
64 return GetCasted(StepShape_GeometricallyBoundedSurfaceShapeRepresentation,Value());
65}
66
67Handle(StepShape_GeometricallyBoundedWireframeShapeRepresentation) StepAP214_AutoDesignGroupedItem::GeometricallyBoundedWireframeShapeRepresentation () const
68{
69 return GetCasted(StepShape_GeometricallyBoundedWireframeShapeRepresentation,Value());
70}
71
72Handle(StepShape_ManifoldSurfaceShapeRepresentation) StepAP214_AutoDesignGroupedItem::ManifoldSurfaceShapeRepresentation () const
73{
74 return GetCasted(StepShape_ManifoldSurfaceShapeRepresentation,Value());
75}
76
77Handle(StepRepr_Representation) StepAP214_AutoDesignGroupedItem::Representation () const
78{
79 return GetCasted(StepRepr_Representation,Value());
80}
81
82Handle(StepRepr_RepresentationItem) StepAP214_AutoDesignGroupedItem::RepresentationItem () const
83{
84 return GetCasted(StepRepr_RepresentationItem,Value());
85}
86
87Handle(StepRepr_ShapeAspect) StepAP214_AutoDesignGroupedItem::ShapeAspect () const
88{
89 return GetCasted(StepRepr_ShapeAspect,Value());
90}
91
92Handle(StepShape_ShapeRepresentation) StepAP214_AutoDesignGroupedItem::ShapeRepresentation () const
93{
94 return GetCasted(StepShape_ShapeRepresentation,Value());
95}
96
97Handle(StepVisual_TemplateInstance) StepAP214_AutoDesignGroupedItem::TemplateInstance () const
98{
99 return GetCasted(StepVisual_TemplateInstance,Value());
100}