b969509fd60888f114ebdc16d5b6fd77b54bac15
[occt.git] / src / StepVisual / StepVisual_AnnotationPlane.hxx
1 // Created on: 2015-10-29
2 // Created by: Irina KRYLOVA
3 // Copyright (c) 2015 OPEN CASCADE SAS
4 //
5 // This file is part of Open CASCADE Technology software library.
6 //
7 // This library is free software; you can redistribute it and/or modify it under
8 // the terms of the GNU Lesser General Public License version 2.1 as published
9 // by the Free Software Foundation, with special exception defined in the file
10 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
11 // distribution for complete text of the license and disclaimer of any warranty.
12 //
13 // Alternatively, this file may be used under the terms of Open CASCADE
14 // commercial license or contractual agreement.
15
16 #ifndef _StepVisual_AnnotationPlane_HeaderFile
17 #define _StepVisual_AnnotationPlane_HeaderFile
18
19 #include <Standard.hxx>
20 #include <Standard_Type.hxx>
21
22 #include <StepVisual_AnnotationOccurrence.hxx>
23 #include <StepVisual_HArray1OfAnnotationPlaneElement.hxx>
24
25 class StepVisual_AnnotationPlane;
26 DEFINE_STANDARD_HANDLE(StepVisual_AnnotationPlane, StepVisual_AnnotationOccurrence)
27
28 class StepVisual_AnnotationPlane : public StepVisual_AnnotationOccurrence
29 {
30 public:
31   
32   //! Returns a AnnotationPlane
33   Standard_EXPORT StepVisual_AnnotationPlane();
34
35   Standard_EXPORT void Init (const Handle(TCollection_HAsciiString)& theName,
36                              const Handle(StepVisual_HArray1OfPresentationStyleAssignment)& theStyles,
37                              const Handle(StepRepr_RepresentationItem)& theItem,
38                              const Handle(StepVisual_HArray1OfAnnotationPlaneElement)& theElements);
39   
40     //! Returns field Elements
41   inline Handle(StepVisual_HArray1OfAnnotationPlaneElement) Elements () const
42   {
43     return myElements;
44   }
45   
46   //! Set field Elements
47   inline void SetElements (const Handle(StepVisual_HArray1OfAnnotationPlaneElement) &theElements)
48   {
49     myElements = theElements;
50   }
51   
52   //! Returns number of Elements
53   inline Standard_Integer NbElements () const
54   {  
55     return (myElements.IsNull() ? 0 : myElements->Length());
56   }
57   
58   //! Returns Elements with the given number
59   inline StepVisual_AnnotationPlaneElement ElementsValue(const Standard_Integer theNum) const
60   {  
61     return myElements->Value(theNum);
62   }
63   
64   //! Sets Elements with given number
65   inline void SetElementsValue(const Standard_Integer theNum, const StepVisual_AnnotationPlaneElement& theItem)
66   {  
67     myElements->SetValue (theNum, theItem);
68   }
69   
70   DEFINE_STANDARD_RTTIEXT(StepVisual_AnnotationPlane,StepVisual_AnnotationOccurrence)
71   
72 private:
73
74   Handle(StepVisual_HArray1OfAnnotationPlaneElement) myElements;
75 };
76 #endif // _StepVisual_AnnotationPlane_HeaderFile