Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:05:35

0001 // Created on: 2001-09-14
0002 // Created by: Alexander GRIGORIEV
0003 // Copyright (c) 2001-2014 OPEN CASCADE SAS
0004 //
0005 // This file is part of Open CASCADE Technology software library.
0006 //
0007 // This library is free software; you can redistribute it and/or modify it under
0008 // the terms of the GNU Lesser General Public License version 2.1 as published
0009 // by the Free Software Foundation, with special exception defined in the file
0010 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0011 // distribution for complete text of the license and disclaimer of any warranty.
0012 //
0013 // Alternatively, this file may be used under the terms of Open CASCADE
0014 // commercial license or contractual agreement.
0015 
0016 #ifndef _XmlMNaming_NamedShapeDriver_HeaderFile
0017 #define _XmlMNaming_NamedShapeDriver_HeaderFile
0018 
0019 #include <Standard.hxx>
0020 #include <Standard_Type.hxx>
0021 
0022 #include <BRepTools_ShapeSet.hxx>
0023 #include <XmlMDF_ADriver.hxx>
0024 #include <TDocStd_FormatVersion.hxx>
0025 #include <XmlObjMgt_RRelocationTable.hxx>
0026 #include <XmlObjMgt_SRelocationTable.hxx>
0027 #include <XmlObjMgt_Element.hxx>
0028 class Message_Messenger;
0029 class TDF_Attribute;
0030 class XmlObjMgt_Persistent;
0031 class TopTools_LocationSet;
0032 
0033 
0034 class XmlMNaming_NamedShapeDriver;
0035 DEFINE_STANDARD_HANDLE(XmlMNaming_NamedShapeDriver, XmlMDF_ADriver)
0036 
0037 
0038 class XmlMNaming_NamedShapeDriver : public XmlMDF_ADriver
0039 {
0040 public:
0041 
0042   Standard_EXPORT XmlMNaming_NamedShapeDriver(const Handle(Message_Messenger)& aMessageDriver);
0043   
0044   Standard_EXPORT virtual Handle(TDF_Attribute) NewEmpty() const Standard_OVERRIDE;
0045   
0046   Standard_EXPORT virtual Standard_Boolean Paste
0047                               (const XmlObjMgt_Persistent& theSource,
0048                                const Handle(TDF_Attribute)& theTarget,
0049                                XmlObjMgt_RRelocationTable& theRelocTable) const Standard_OVERRIDE;
0050   
0051   Standard_EXPORT virtual void Paste
0052                               (const Handle(TDF_Attribute)& theSource,
0053                                XmlObjMgt_Persistent& theTarget,
0054                                XmlObjMgt_SRelocationTable& theRelocTable) const Standard_OVERRIDE;
0055   
0056   //! Input the shapes from DOM element
0057   Standard_EXPORT void ReadShapeSection (const XmlObjMgt_Element& anElement,
0058                                          const Message_ProgressRange& theRange = Message_ProgressRange());
0059   
0060   //! Output the shapes into DOM element
0061   Standard_EXPORT void WriteShapeSection (XmlObjMgt_Element& anElement,
0062                                           TDocStd_FormatVersion theStorageFormatVersion,
0063                                           const Message_ProgressRange& theRange = Message_ProgressRange());
0064   
0065   //! Clear myShapeSet
0066   Standard_EXPORT void Clear();
0067   
0068   //! get the format of topology
0069     TopTools_LocationSet& GetShapesLocations();
0070 
0071   DEFINE_STANDARD_RTTIEXT(XmlMNaming_NamedShapeDriver,XmlMDF_ADriver)
0072 
0073 private:
0074 
0075   BRepTools_ShapeSet myShapeSet;
0076 
0077 };
0078 
0079 
0080 #include <XmlMNaming_NamedShapeDriver.lxx>
0081 
0082 #endif // _XmlMNaming_NamedShapeDriver_HeaderFile