42cf5bc1 |
1 | // Created on: 2001-09-14 |
2 | // Created by: Alexander GRIGORIEV |
3 | // Copyright (c) 2001-2014 OPEN CASCADE SAS |
4 | // |
5 | // This file is part of Open CASCADE Technology software library. |
6 | // |
7 | // This library is free software; you can redistribute it and/or modify it under |
8 | // the terms of the GNU Lesser General Public License version 2.1 as published |
9 | // by the Free Software Foundation, with special exception defined in the file |
10 | // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT |
11 | // distribution for complete text of the license and disclaimer of any warranty. |
12 | // |
13 | // Alternatively, this file may be used under the terms of Open CASCADE |
14 | // commercial license or contractual agreement. |
15 | |
16 | #ifndef _XmlMNaming_NamedShapeDriver_HeaderFile |
17 | #define _XmlMNaming_NamedShapeDriver_HeaderFile |
18 | |
19 | #include <Standard.hxx> |
20 | #include <Standard_Type.hxx> |
21 | |
22 | #include <BRepTools_ShapeSet.hxx> |
23 | #include <XmlMDF_ADriver.hxx> |
24 | #include <Standard_Boolean.hxx> |
25 | #include <XmlObjMgt_RRelocationTable.hxx> |
26 | #include <XmlObjMgt_SRelocationTable.hxx> |
27 | #include <XmlObjMgt_Element.hxx> |
28 | class CDM_MessageDriver; |
29 | class TDF_Attribute; |
30 | class XmlObjMgt_Persistent; |
31 | class TopTools_LocationSet; |
32 | |
33 | |
34 | class XmlMNaming_NamedShapeDriver; |
35 | DEFINE_STANDARD_HANDLE(XmlMNaming_NamedShapeDriver, XmlMDF_ADriver) |
36 | |
37 | |
38 | class XmlMNaming_NamedShapeDriver : public XmlMDF_ADriver |
39 | { |
40 | |
41 | public: |
42 | |
43 | |
44 | Standard_EXPORT XmlMNaming_NamedShapeDriver(const Handle(CDM_MessageDriver)& aMessageDriver); |
45 | |
46 | Standard_EXPORT virtual Handle(TDF_Attribute) NewEmpty() const Standard_OVERRIDE; |
47 | |
48 | Standard_EXPORT virtual Standard_Boolean Paste (const XmlObjMgt_Persistent& theSource, const Handle(TDF_Attribute)& theTarget, XmlObjMgt_RRelocationTable& theRelocTable) const Standard_OVERRIDE; |
49 | |
50 | Standard_EXPORT virtual void Paste (const Handle(TDF_Attribute)& theSource, XmlObjMgt_Persistent& theTarget, XmlObjMgt_SRelocationTable& theRelocTable) const Standard_OVERRIDE; |
51 | |
52 | //! Input the shapes from DOM element |
53 | Standard_EXPORT void ReadShapeSection (const XmlObjMgt_Element& anElement); |
54 | |
55 | //! Output the shapes into DOM element |
56 | Standard_EXPORT void WriteShapeSection (XmlObjMgt_Element& anElement); |
57 | |
58 | //! Clear myShapeSet |
59 | Standard_EXPORT void Clear(); |
60 | |
61 | //! get the format of topology |
62 | TopTools_LocationSet& GetShapesLocations(); |
63 | |
64 | |
65 | |
66 | |
92efcf78 |
67 | DEFINE_STANDARD_RTTIEXT(XmlMNaming_NamedShapeDriver,XmlMDF_ADriver) |
42cf5bc1 |
68 | |
69 | protected: |
70 | |
71 | |
72 | |
73 | |
74 | private: |
75 | |
76 | |
77 | BRepTools_ShapeSet myShapeSet; |
78 | |
79 | |
80 | }; |
81 | |
82 | |
83 | #include <XmlMNaming_NamedShapeDriver.lxx> |
84 | |
85 | |
86 | |
87 | |
88 | |
89 | #endif // _XmlMNaming_NamedShapeDriver_HeaderFile |