summaryrefslogtreecommitdiff
path: root/drv/ShapeSchema/ShapeSchema_gp_Trsf.cxx
blob: 47c072f489226b4fb0de9c4ebb7a447f498219e6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#ifndef _ShapeSchema_gp_Trsf_HeaderFile
#include <ShapeSchema_gp_Trsf.hxx>
#endif
#ifndef _gp_Trsf_HeaderFile
#include <gp_Trsf.hxx>
#endif
#include <ShapeSchema_gp_Trsf.ixx>
#ifndef _Storage_Schema_HeaderFile
#include <Storage_Schema.hxx>
#endif
#ifndef _Storage_stCONSTclCOM_HeaderFile
#include <Storage_stCONSTclCOM.hxx>
#endif

void ShapeSchema_gp_Trsf::SWrite(const gp_Trsf& pp, Storage_BaseDriver& f, const Handle(Storage_Schema)& theSchema)
{
  f.BeginWriteObjectData();
  f.PutReal(pp._CSFDB_Getgp_Trsfscale());
  f.PutInteger(pp._CSFDB_Getgp_Trsfshape());
    ShapeSchema_gp_Mat::SWrite(pp._CSFDB_Getgp_Trsfmatrix(),f,theSchema);
    ShapeSchema_gp_XYZ::SWrite(pp._CSFDB_Getgp_Trsfloc(),f,theSchema);

  f.EndWriteObjectData();
}

void ShapeSchema_gp_Trsf::SRead(gp_Trsf& pp, Storage_BaseDriver& f, const Handle(Storage_Schema)& theSchema)
{
  f.BeginReadObjectData();

    Standard_Real gp_Trsfscale;
    f.GetReal(gp_Trsfscale);
    pp._CSFDB_Setgp_Trsfscale(gp_Trsfscale);

    gp_TrsfForm gp_Trsfshape;
    Standard_Integer i_CSFDB_gp_Trsfshape;
    f.GetInteger(i_CSFDB_gp_Trsfshape);
    gp_Trsfshape = (gp_TrsfForm)i_CSFDB_gp_Trsfshape;
    pp._CSFDB_Setgp_Trsfshape(gp_Trsfshape);

    ShapeSchema_gp_Mat::SRead((gp_Mat&)pp._CSFDB_Getgp_Trsfmatrix(),f,theSchema);

    ShapeSchema_gp_XYZ::SRead((gp_XYZ&)pp._CSFDB_Getgp_Trsfloc(),f,theSchema);

  f.EndReadObjectData();
}