0031668: Visualization - WebGL sample doesn't work on Emscripten 1.39
[occt.git] / src / RWStepBasic / RWStepBasic_RWActionRequestSolution.cxx
1 // Created on: 1999-11-26
2 // Created by: Andrey BETENEV
3 // Copyright (c) 1999 Matra Datavision
4 // Copyright (c) 1999-2014 OPEN CASCADE SAS
5 //
6 // This file is part of Open CASCADE Technology software library.
7 //
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
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.
13 //
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
16
17 // Generator:   ExpToCas (EXPRESS -> CASCADE/XSTEP Translator) V1.0
18
19 #include <Interface_Check.hxx>
20 #include <Interface_EntityIterator.hxx>
21 #include <RWStepBasic_RWActionRequestSolution.hxx>
22 #include <StepBasic_ActionMethod.hxx>
23 #include <StepBasic_ActionRequestSolution.hxx>
24 #include <StepBasic_VersionedActionRequest.hxx>
25 #include <StepData_StepReaderData.hxx>
26 #include <StepData_StepWriter.hxx>
27
28 //=======================================================================
29 //function : RWStepBasic_RWActionRequestSolution
30 //purpose  : 
31 //=======================================================================
32 RWStepBasic_RWActionRequestSolution::RWStepBasic_RWActionRequestSolution ()
33 {
34 }
35
36 //=======================================================================
37 //function : ReadStep
38 //purpose  : 
39 //=======================================================================
40
41 void RWStepBasic_RWActionRequestSolution::ReadStep (const Handle(StepData_StepReaderData)& data,
42                                                     const Standard_Integer num,
43                                                     Handle(Interface_Check)& ach,
44                                                     const Handle(StepBasic_ActionRequestSolution) &ent) const
45 {
46   // Check number of parameters
47   if ( ! data->CheckNbParams(num,2,ach,"action_request_solution") ) return;
48
49   // Own fields of ActionRequestSolution
50
51   Handle(StepBasic_ActionMethod) aMethod;
52   data->ReadEntity (num, 1, "method", ach, STANDARD_TYPE(StepBasic_ActionMethod), aMethod);
53
54   Handle(StepBasic_VersionedActionRequest) aRequest;
55   data->ReadEntity (num, 2, "request", ach, STANDARD_TYPE(StepBasic_VersionedActionRequest), aRequest);
56
57   // Initialize entity
58   ent->Init(aMethod,
59             aRequest);
60 }
61
62 //=======================================================================
63 //function : WriteStep
64 //purpose  : 
65 //=======================================================================
66
67 void RWStepBasic_RWActionRequestSolution::WriteStep (StepData_StepWriter& SW,
68                                                      const Handle(StepBasic_ActionRequestSolution) &ent) const
69 {
70
71   // Own fields of ActionRequestSolution
72
73   SW.Send (ent->Method());
74
75   SW.Send (ent->Request());
76 }
77
78 //=======================================================================
79 //function : Share
80 //purpose  : 
81 //=======================================================================
82
83 void RWStepBasic_RWActionRequestSolution::Share (const Handle(StepBasic_ActionRequestSolution) &ent,
84                                                  Interface_EntityIterator& iter) const
85 {
86
87   // Own fields of ActionRequestSolution
88
89   iter.AddItem (ent->Method());
90
91   iter.AddItem (ent->Request());
92 }