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
6 // This file is part of Open CASCADE Technology software library.
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.
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
17 // Generator: ExpToCas (EXPRESS -> CASCADE/XSTEP Translator) V1.0
19 #include <Interface_EntityIterator.hxx>
20 #include <RWStepBasic_RWVersionedActionRequest.hxx>
21 #include <StepBasic_VersionedActionRequest.hxx>
22 #include <StepData_StepReaderData.hxx>
23 #include <StepData_StepWriter.hxx>
25 //=======================================================================
26 //function : RWStepBasic_RWVersionedActionRequest
28 //=======================================================================
29 RWStepBasic_RWVersionedActionRequest::RWStepBasic_RWVersionedActionRequest ()
33 //=======================================================================
36 //=======================================================================
38 void RWStepBasic_RWVersionedActionRequest::ReadStep (const Handle(StepData_StepReaderData)& data,
39 const Standard_Integer num,
40 Handle(Interface_Check)& ach,
41 const Handle(StepBasic_VersionedActionRequest) &ent) const
43 // Check number of parameters
44 if ( ! data->CheckNbParams(num,4,ach,"versioned_action_request") ) return;
46 // Own fields of VersionedActionRequest
48 Handle(TCollection_HAsciiString) aId;
49 data->ReadString (num, 1, "id", ach, aId);
51 Handle(TCollection_HAsciiString) aVersion;
52 data->ReadString (num, 2, "version", ach, aVersion);
54 Handle(TCollection_HAsciiString) aPurpose;
55 data->ReadString (num, 3, "purpose", ach, aPurpose);
57 Handle(TCollection_HAsciiString) aDescription;
58 Standard_Boolean hasDescription = Standard_True;
59 if ( data->IsParamDefined (num,4) ) {
60 data->ReadString (num, 4, "description", ach, aDescription);
63 hasDescription = Standard_False;
74 //=======================================================================
75 //function : WriteStep
77 //=======================================================================
79 void RWStepBasic_RWVersionedActionRequest::WriteStep (StepData_StepWriter& SW,
80 const Handle(StepBasic_VersionedActionRequest) &ent) const
83 // Own fields of VersionedActionRequest
87 SW.Send (ent->Version());
89 SW.Send (ent->Purpose());
91 if ( ent->HasDescription() ) {
92 SW.Send (ent->Description());
97 //=======================================================================
100 //=======================================================================
102 void RWStepBasic_RWVersionedActionRequest::Share (const Handle(StepBasic_VersionedActionRequest) &,
103 Interface_EntityIterator&) const
106 // Own fields of VersionedActionRequest