0026912: CLang 3.6.2 compiler warning [-Winconsistent-missing-override]
[occt.git] / src / StepGeom / StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx.cxx
CommitLineData
b311480e 1// Created on: 1995-12-07
2// Created by: Frederic MAUPAS
3// Copyright (c) 1995-1999 Matra Datavision
973c2be1 4// Copyright (c) 1999-2014 OPEN CASCADE SAS
b311480e 5//
973c2be1 6// This file is part of Open CASCADE Technology software library.
b311480e 7//
d5f74e42 8// This library is free software; you can redistribute it and/or modify it under
9// the terms of the GNU Lesser General Public License version 2.1 as published
973c2be1 10// by the Free Software Foundation, with special exception defined in the file
11// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12// distribution for complete text of the license and disclaimer of any warranty.
b311480e 13//
973c2be1 14// Alternatively, this file may be used under the terms of Open CASCADE
15// commercial license or contractual agreement.
7fd59977 16
7fd59977 17
42cf5bc1 18#include <Standard_Type.hxx>
19#include <StepBasic_NamedUnit.hxx>
20#include <StepBasic_UncertaintyMeasureWithUnit.hxx>
7fd59977 21#include <StepGeom_GeometricRepresentationContext.hxx>
42cf5bc1 22#include <StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx.hxx>
23#include <StepRepr_GlobalUncertaintyAssignedContext.hxx>
7fd59977 24#include <StepRepr_GlobalUnitAssignedContext.hxx>
42cf5bc1 25#include <TCollection_HAsciiString.hxx>
7fd59977 26
27// --------------------------------------------------------------------------------------------------
28// Method :
29// Purpose :
30// --------------------------------------------------------------------------------------------------
7fd59977 31StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx () {}
32
33// --------------------------------------------------------------------------------------------------
34// Method :
35// Purpose :
36// --------------------------------------------------------------------------------------------------
37
38void StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::Init
39(const Handle(TCollection_HAsciiString)& aContextIdentifier,
40 const Handle(TCollection_HAsciiString)& aContextType)
41{
42 StepRepr_RepresentationContext::Init(aContextIdentifier, aContextType);
43}
44
45// --------------------------------------------------------------------------------------------------
46// Method :
47// Purpose :
48// --------------------------------------------------------------------------------------------------
49
50void StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::Init
51(const Handle(TCollection_HAsciiString)& aContextIdentifier,
52 const Handle(TCollection_HAsciiString)& aContextType,
53 const Handle(StepGeom_GeometricRepresentationContext)& aGeometricRepresentationContext,
54 const Handle(StepRepr_GlobalUnitAssignedContext)& aGlobalUnitAssignedContext,
55 const Handle(StepRepr_GlobalUncertaintyAssignedContext)& aGlobalUncertaintyAssignedCtx)
56{
57 // --- classe own fields ---
58 geometricRepresentationContext = aGeometricRepresentationContext;
59 globalUnitAssignedContext = aGlobalUnitAssignedContext;
60 globalUncertaintyAssignedContext = aGlobalUncertaintyAssignedCtx;
61 // --- classe inherited fields ---
62 StepRepr_RepresentationContext::Init(aContextIdentifier, aContextType);
63}
64
65
66// --------------------------------------------------------------------------------------------------
67// Method :
68// Purpose :
69// --------------------------------------------------------------------------------------------------
70
71void StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::Init
72(const Handle(TCollection_HAsciiString)& aContextIdentifier,
73 const Handle(TCollection_HAsciiString)& aContextType,
74 const Standard_Integer aCoordinateSpaceDimension,
75 const Handle(StepBasic_HArray1OfNamedUnit)& aUnits,
76 const Handle(StepBasic_HArray1OfUncertaintyMeasureWithUnit)& anUncertainty)
77{
78 // --- classe inherited fields ---
79
80 StepRepr_RepresentationContext::Init(aContextIdentifier, aContextType);
81
82 // --- ANDOR componant fields : GeometricRepresentationContext ---
83
84 geometricRepresentationContext = new StepGeom_GeometricRepresentationContext();
85 geometricRepresentationContext->Init(aContextIdentifier, aContextType, aCoordinateSpaceDimension);
86
87 // --- ANDOR componant fields : GlobalUnitAssignedContext ---
88
89 globalUnitAssignedContext = new StepRepr_GlobalUnitAssignedContext();
90 globalUnitAssignedContext->Init(aContextIdentifier, aContextType, aUnits);
91
92 // --- ANDOR componant fields : GlobalUncertaintyAssignedContext ---
93
94 globalUncertaintyAssignedContext = new StepRepr_GlobalUncertaintyAssignedContext();
95 globalUncertaintyAssignedContext->Init(aContextIdentifier, aContextType, anUncertainty);
96
97}
98
99// --------------------------------------------------------------------------------------------------
100// Method :
101// Purpose :
102// --------------------------------------------------------------------------------------------------
103
104void StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::SetGeometricRepresentationContext(const Handle(StepGeom_GeometricRepresentationContext)& aGeometricRepresentationContext)
105{
106 geometricRepresentationContext = aGeometricRepresentationContext;
107}
108
109// --------------------------------------------------------------------------------------------------
110// Method :
111// Purpose :
112// --------------------------------------------------------------------------------------------------
113
114Handle(StepGeom_GeometricRepresentationContext) StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::GeometricRepresentationContext() const
115{
116 return geometricRepresentationContext;
117}
118
119// --------------------------------------------------------------------------------------------------
120// Method :
121// Purpose :
122// --------------------------------------------------------------------------------------------------
123
124void StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::SetGlobalUnitAssignedContext
125(const Handle(StepRepr_GlobalUnitAssignedContext)& aGlobalUnitAssignedContext)
126{
127 globalUnitAssignedContext = aGlobalUnitAssignedContext;
128}
129
130// --------------------------------------------------------------------------------------------------
131// Method :
132// Purpose :
133// --------------------------------------------------------------------------------------------------
134
135Handle(StepRepr_GlobalUnitAssignedContext) StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::GlobalUnitAssignedContext() const
136{
137 return globalUnitAssignedContext;
138}
139
140// --------------------------------------------------------------------------------------------------
141// Method :
142// Purpose :
143// --------------------------------------------------------------------------------------------------
144
145void StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::SetGlobalUncertaintyAssignedContext
146(const Handle(StepRepr_GlobalUncertaintyAssignedContext)& aGlobalUncertaintyAssignedCtx)
147{
148 globalUncertaintyAssignedContext = aGlobalUncertaintyAssignedCtx;
149}
150
151
152// --------------------------------------------------------------------------------------------------
153// Method :
154// Purpose :
155// --------------------------------------------------------------------------------------------------
156
157Handle(StepRepr_GlobalUncertaintyAssignedContext) StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::GlobalUncertaintyAssignedContext() const
158{
159 return globalUncertaintyAssignedContext;
160}
161
162//-------------------------------------------------------------------------------------
163//--- Specific Methods for AND classe field access : GeometricRepresentationContext ---
164//-------------------------------------------------------------------------------------
165
166// --------------------------------------------------------------------------------------------------
167// Method :
168// Purpose :
169// --------------------------------------------------------------------------------------------------
170
171void StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::SetCoordinateSpaceDimension(const Standard_Integer aCoordinateSpaceDimension)
172{
173 geometricRepresentationContext->SetCoordinateSpaceDimension(aCoordinateSpaceDimension);
174}
175
176// --------------------------------------------------------------------------------------------------
177// Method :
178// Purpose :
179// --------------------------------------------------------------------------------------------------
180
181Standard_Integer StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::CoordinateSpaceDimension() const
182{
183 return geometricRepresentationContext->CoordinateSpaceDimension();
184}
185
186//---------------------------------------------------------------------------------
187//--- Specific Methods for AND classe field access : GlobalUnitAssignedContext ---
188//---------------------------------------------------------------------------------
189
190// --------------------------------------------------------------------------------------------------
191// Method :
192// Purpose :
193// --------------------------------------------------------------------------------------------------
194
195void StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::SetUnits(const Handle(StepBasic_HArray1OfNamedUnit)& aUnits)
196{
197 globalUnitAssignedContext->SetUnits(aUnits);
198}
199
200// --------------------------------------------------------------------------------------------------
201// Method :
202// Purpose :
203// --------------------------------------------------------------------------------------------------
204
205Handle(StepBasic_HArray1OfNamedUnit) StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::Units() const
206{
207 return globalUnitAssignedContext->Units();
208}
209
210// --------------------------------------------------------------------------------------------------
211// Method :
212// Purpose :
213// --------------------------------------------------------------------------------------------------
214
215Handle(StepBasic_NamedUnit) StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::UnitsValue(const Standard_Integer num) const
216{
217 return globalUnitAssignedContext->UnitsValue(num);
218}
219
220// --------------------------------------------------------------------------------------------------
221// Method :
222// Purpose :
223// --------------------------------------------------------------------------------------------------
224
225Standard_Integer StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::NbUnits () const
226{
227 return globalUnitAssignedContext->NbUnits();
228}
229
230
231//----------------------------------------------------------------------------------------
232//--- Specific Methods for AND classe field access : GlobalUncertaintyAssignedContext ---
233//----------------------------------------------------------------------------------------
234
235// --------------------------------------------------------------------------------------------------
236// Method :
237// Purpose :
238// --------------------------------------------------------------------------------------------------
239
240void StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::SetUncertainty(const Handle(StepBasic_HArray1OfUncertaintyMeasureWithUnit)& aUncertainty)
241{
242 globalUncertaintyAssignedContext->SetUncertainty(aUncertainty);
243}
244
245// --------------------------------------------------------------------------------------------------
246// Method :
247// Purpose :
248// --------------------------------------------------------------------------------------------------
249
250Handle(StepBasic_HArray1OfUncertaintyMeasureWithUnit) StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::Uncertainty() const
251{
252 return globalUncertaintyAssignedContext->Uncertainty();
253}
254
255// --------------------------------------------------------------------------------------------------
256// Method :
257// Purpose :
258// --------------------------------------------------------------------------------------------------
259
260Handle(StepBasic_UncertaintyMeasureWithUnit) StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::UncertaintyValue(const Standard_Integer num) const
261{
262 return globalUncertaintyAssignedContext->UncertaintyValue(num);
263}
264
265// --------------------------------------------------------------------------------------------------
266// Method :
267// Purpose :
268// --------------------------------------------------------------------------------------------------
269
270Standard_Integer StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx::NbUncertainty() const
271{
272 return globalUncertaintyAssignedContext->NbUncertainty();
273}