Back to home page

EIC code displayed by LXR

 
 

    


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

0001 // Created on: 2010-11-15
0002 // Created by: Sergey SLYADNEV
0003 // Copyright (c) 2010-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 _StepToTopoDS_NMTool_HeaderFile
0017 #define _StepToTopoDS_NMTool_HeaderFile
0018 
0019 #include <Standard.hxx>
0020 #include <Standard_DefineAlloc.hxx>
0021 #include <Standard_Handle.hxx>
0022 
0023 #include <StepToTopoDS_DataMapOfRI.hxx>
0024 #include <StepToTopoDS_DataMapOfRINames.hxx>
0025 #include <TopTools_ListOfShape.hxx>
0026 #include <Standard_Boolean.hxx>
0027 class StepRepr_RepresentationItem;
0028 class TCollection_AsciiString;
0029 class TopoDS_Shape;
0030 
0031 
0032 //! Provides data to process non-manifold topology when
0033 //! reading from STEP.
0034 class StepToTopoDS_NMTool 
0035 {
0036 public:
0037 
0038   DEFINE_STANDARD_ALLOC
0039 
0040   
0041   Standard_EXPORT StepToTopoDS_NMTool();
0042   
0043   Standard_EXPORT StepToTopoDS_NMTool(const StepToTopoDS_DataMapOfRI& MapOfRI, const StepToTopoDS_DataMapOfRINames& MapOfRINames);
0044   
0045   Standard_EXPORT void Init (const StepToTopoDS_DataMapOfRI& MapOfRI, const StepToTopoDS_DataMapOfRINames& MapOfRINames);
0046   
0047   Standard_EXPORT void SetActive (const Standard_Boolean isActive);
0048   
0049   Standard_EXPORT Standard_Boolean IsActive();
0050   
0051   Standard_EXPORT void CleanUp();
0052   
0053   Standard_EXPORT Standard_Boolean IsBound (const Handle(StepRepr_RepresentationItem)& RI);
0054   
0055   Standard_EXPORT Standard_Boolean IsBound (const TCollection_AsciiString& RIName);
0056   
0057   Standard_EXPORT void Bind (const Handle(StepRepr_RepresentationItem)& RI, const TopoDS_Shape& S);
0058   
0059   Standard_EXPORT void Bind (const TCollection_AsciiString& RIName, const TopoDS_Shape& S);
0060   
0061   Standard_EXPORT const TopoDS_Shape& Find (const Handle(StepRepr_RepresentationItem)& RI);
0062   
0063   Standard_EXPORT const TopoDS_Shape& Find (const TCollection_AsciiString& RIName);
0064   
0065   Standard_EXPORT void RegisterNMEdge (const TopoDS_Shape& Edge);
0066   
0067   Standard_EXPORT Standard_Boolean IsSuspectedAsClosing (const TopoDS_Shape& BaseShell, const TopoDS_Shape& SuspectedShell);
0068   
0069   Standard_EXPORT Standard_Boolean IsPureNMShell (const TopoDS_Shape& Shell);
0070   
0071   Standard_EXPORT void SetIDEASCase (const Standard_Boolean IDEASCase);
0072   
0073   Standard_EXPORT Standard_Boolean IsIDEASCase();
0074 
0075 
0076 
0077 
0078 protected:
0079 
0080 
0081 
0082 
0083 
0084 private:
0085 
0086   
0087   Standard_EXPORT Standard_Boolean isEdgeRegisteredAsNM (const TopoDS_Shape& Edge);
0088   
0089   Standard_EXPORT Standard_Boolean isAdjacentShell (const TopoDS_Shape& ShellA, const TopoDS_Shape& ShellB);
0090 
0091 
0092   StepToTopoDS_DataMapOfRI myRIMap;
0093   StepToTopoDS_DataMapOfRINames myRINamesMap;
0094   TopTools_ListOfShape myNMEdges;
0095   Standard_Boolean myIDEASCase;
0096   Standard_Boolean myActiveFlag;
0097 
0098 
0099 };
0100 
0101 
0102 
0103 
0104 
0105 
0106 
0107 #endif // _StepToTopoDS_NMTool_HeaderFile