0027961: Visualization - remove unused and no more working OpenGl_AVIWriter
[occt.git] / src / RWStepBasic / RWStepBasic_RWDimensionalExponents.cxx
1 // Copyright (c) 1999-2014 OPEN CASCADE SAS
2 //
3 // This file is part of Open CASCADE Technology software library.
4 //
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.
10 //
11 // Alternatively, this file may be used under the terms of Open CASCADE
12 // commercial license or contractual agreement.
13
14
15 #include <Interface_Check.hxx>
16 #include <RWStepBasic_RWDimensionalExponents.hxx>
17 #include <StepBasic_DimensionalExponents.hxx>
18 #include <StepData_StepReaderData.hxx>
19 #include <StepData_StepWriter.hxx>
20
21 RWStepBasic_RWDimensionalExponents::RWStepBasic_RWDimensionalExponents () {}
22
23 void RWStepBasic_RWDimensionalExponents::ReadStep
24         (const Handle(StepData_StepReaderData)& data,
25          const Standard_Integer num,
26          Handle(Interface_Check)& ach,
27          const Handle(StepBasic_DimensionalExponents)& ent) const
28 {
29
30
31         // --- Number of Parameter Control ---
32
33         if (!data->CheckNbParams(num,7,ach,"dimensional_exponents")) return;
34
35         // --- own field : lengthExponent ---
36
37         Standard_Real aLengthExponent;
38         //szv#4:S4163:12Mar99 `Standard_Boolean stat1 =` not needed
39         data->ReadReal (num,1,"length_exponent",ach,aLengthExponent);
40
41         // --- own field : massExponent ---
42
43         Standard_Real aMassExponent;
44         //szv#4:S4163:12Mar99 `Standard_Boolean stat2 =` not needed
45         data->ReadReal (num,2,"mass_exponent",ach,aMassExponent);
46
47         // --- own field : timeExponent ---
48
49         Standard_Real aTimeExponent;
50         //szv#4:S4163:12Mar99 `Standard_Boolean stat3 =` not needed
51         data->ReadReal (num,3,"time_exponent",ach,aTimeExponent);
52
53         // --- own field : electricCurrentExponent ---
54
55         Standard_Real aElectricCurrentExponent;
56         //szv#4:S4163:12Mar99 `Standard_Boolean stat4 =` not needed
57         data->ReadReal (num,4,"electric_current_exponent",ach,aElectricCurrentExponent);
58
59         // --- own field : thermodynamicTemperatureExponent ---
60
61         Standard_Real aThermodynamicTemperatureExponent;
62         //szv#4:S4163:12Mar99 `Standard_Boolean stat5 =` not needed
63         data->ReadReal (num,5,"thermodynamic_temperature_exponent",ach,aThermodynamicTemperatureExponent);
64
65         // --- own field : amountOfSubstanceExponent ---
66
67         Standard_Real aAmountOfSubstanceExponent;
68         //szv#4:S4163:12Mar99 `Standard_Boolean stat6 =` not needed
69         data->ReadReal (num,6,"amount_of_substance_exponent",ach,aAmountOfSubstanceExponent);
70
71         // --- own field : luminousIntensityExponent ---
72
73         Standard_Real aLuminousIntensityExponent;
74         //szv#4:S4163:12Mar99 `Standard_Boolean stat7 =` not needed
75         data->ReadReal (num,7,"luminous_intensity_exponent",ach,aLuminousIntensityExponent);
76
77         //--- Initialisation of the read entity ---
78
79
80         ent->Init(aLengthExponent, aMassExponent, aTimeExponent, aElectricCurrentExponent, aThermodynamicTemperatureExponent, aAmountOfSubstanceExponent, aLuminousIntensityExponent);
81 }
82
83
84 void RWStepBasic_RWDimensionalExponents::WriteStep
85         (StepData_StepWriter& SW,
86          const Handle(StepBasic_DimensionalExponents)& ent) const
87 {
88
89         // --- own field : lengthExponent ---
90
91         SW.Send(ent->LengthExponent());
92
93         // --- own field : massExponent ---
94
95         SW.Send(ent->MassExponent());
96
97         // --- own field : timeExponent ---
98
99         SW.Send(ent->TimeExponent());
100
101         // --- own field : electricCurrentExponent ---
102
103         SW.Send(ent->ElectricCurrentExponent());
104
105         // --- own field : thermodynamicTemperatureExponent ---
106
107         SW.Send(ent->ThermodynamicTemperatureExponent());
108
109         // --- own field : amountOfSubstanceExponent ---
110
111         SW.Send(ent->AmountOfSubstanceExponent());
112
113         // --- own field : luminousIntensityExponent ---
114
115         SW.Send(ent->LuminousIntensityExponent());
116 }