1 // Copyright (c) 1999-2014 OPEN CASCADE SAS
3 // This file is part of Open CASCADE Technology software library.
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.
11 // Alternatively, this file may be used under the terms of Open CASCADE
12 // commercial license or contractual agreement.
14 // abv 09.04.99 S4136: eliminate parameter step.readaccept.void
15 // svv #2 23.02.00: porting on SIL
17 #include <Interface_Macros.hxx>
18 #include <Interface_Static.hxx>
19 #include <Interface_Statics.hxx>
20 #include <StepData.hxx>
21 #include <StepData_DefaultGeneral.hxx>
22 #include <StepData_FileProtocol.hxx>
23 #include <StepData_Protocol.hxx>
25 StaticHandle(StepData_Protocol,proto);
26 //svv #2: StaticHandle(StepData_DefaultGeneral,stmod);
28 StaticHandleA(StepData_Protocol,theheader);
31 void StepData::Init ()
33 // InitHandleVoid(StepData_Protocol,proto);
34 // InitHandleVoid(StepData_DefaultGeneral,stmod);
35 //:S4136 Interface_Static::Init("step","step.readaccept.void",'i',"1");
36 // if (proto.IsNull()) proto = new StepData_Protocol;
37 // if (stmod.IsNull()) stmod = new StepData_DefaultGeneral;
40 Handle(StepData_Protocol) StepData::Protocol ()
42 InitHandleVoid(StepData_Protocol,proto);// svv #2
43 // UseHandle(StepData_Protocol,proto);
48 void StepData::AddHeaderProtocol (const Handle(StepData_Protocol)& header)
50 InitHandle(StepData_Protocol,theheader);
51 if (theheader.IsNull()) theheader = header;
53 DeclareAndCast(StepData_FileProtocol,headmult,theheader);
54 if (headmult.IsNull()) {
55 headmult = new StepData_FileProtocol;
56 headmult->Add(theheader);
58 headmult->Add(header);
63 Handle(StepData_Protocol) StepData::HeaderProtocol ()
65 UseHandle(StepData_Protocol,theheader);