1 // Copyright (c) 1999-2014 OPEN CASCADE SAS
3 // This file is part of Open CASCADE Technology software library.
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
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.
11 // Alternatively, this file may be used under the terms of Open CASCADE
12 // commercial license or contractual agreement.
15 #include <Interface_Macros.hxx>
16 #include <Standard_Transient.hxx>
17 #include <StepVisual_CurveStyle.hxx>
18 #include <StepVisual_FillAreaStyle.hxx>
19 #include <StepVisual_NullStyleMember.hxx>
20 #include <StepVisual_PointStyle.hxx>
21 #include <StepVisual_PresentationStyleSelect.hxx>
22 #include <StepVisual_SurfaceStyleUsage.hxx>
23 #include <StepVisual_TextStyle.hxx>
25 StepVisual_PresentationStyleSelect::StepVisual_PresentationStyleSelect () { }
27 Standard_Integer StepVisual_PresentationStyleSelect::CaseNum(const Handle(Standard_Transient)& ent) const
29 if (ent.IsNull()) return 0;
30 if (ent->IsKind(STANDARD_TYPE(StepVisual_PointStyle))) return 1;
31 if (ent->IsKind(STANDARD_TYPE(StepVisual_CurveStyle))) return 2;
32 if (ent->IsKind(STANDARD_TYPE(StepVisual_SurfaceStyleUsage))) return 3;
33 // if (ent->IsKind(STANDARD_TYPE(StepVisual_SymbolStyle))) return 4;
34 // if (ent->IsKind(STANDARD_TYPE(StepVisual_FillAreaStyle))) return 5;
35 // if (ent->IsKind(STANDARD_TYPE(StepVisual_TextStyle))) return 6;
36 if (ent->IsKind(STANDARD_TYPE(StepVisual_NullStyleMember))) return 7;
40 Handle(StepVisual_PointStyle) StepVisual_PresentationStyleSelect::PointStyle () const
42 return GetCasted(StepVisual_PointStyle,Value());
45 Handle(StepVisual_CurveStyle) StepVisual_PresentationStyleSelect::CurveStyle () const
47 return GetCasted(StepVisual_CurveStyle,Value());
50 Handle(StepVisual_NullStyleMember) StepVisual_PresentationStyleSelect::NullStyle () const
52 return GetCasted(StepVisual_NullStyleMember,Value());
55 Handle(StepVisual_SurfaceStyleUsage) StepVisual_PresentationStyleSelect::SurfaceStyleUsage () const
57 return GetCasted(StepVisual_SurfaceStyleUsage,Value());