Back to home page

EIC code displayed by LXR

 
 

    


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

0001 // Created on: 2015-08-06
0002 // Created by: Ilya Novikov
0003 // Copyright (c) 2004-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 
0017 #ifndef _XCAFDimTolObjects_Tool_HeaderFile
0018 #define _XCAFDimTolObjects_Tool_HeaderFile
0019 
0020 #include <Standard.hxx>
0021 #include <Standard_Type.hxx>
0022 
0023 #include <XCAFDoc_DimTolTool.hxx>
0024 #include <TDocStd_Document.hxx>
0025 #include <Standard_Boolean.hxx>
0026 #include <XCAFDimTolObjects_DimensionObjectSequence.hxx>
0027 #include <XCAFDimTolObjects_GeomToleranceObjectSequence.hxx>
0028 #include <XCAFDimTolObjects_DatumObjectSequence.hxx>
0029 #include <XCAFDimTolObjects_DataMapOfToleranceDatum.hxx>
0030 #include <XCAFDimTolObjects_DatumObject.hxx>
0031 class TDocStd_Document;
0032 class TopoDS_Shape;
0033 
0034 
0035 class XCAFDimTolObjects_Tool 
0036 {
0037 public:
0038 
0039   DEFINE_STANDARD_ALLOC
0040 
0041   
0042   Standard_EXPORT XCAFDimTolObjects_Tool(const Handle(TDocStd_Document)& theDoc);
0043   
0044   //! Returns a sequence of Dimensions currently stored
0045   //! in the GD&T table
0046   Standard_EXPORT void GetDimensions (XCAFDimTolObjects_DimensionObjectSequence& theDimensionObjectSequence) const;
0047   
0048   //! Returns all Dimensions defined for Shape
0049   Standard_EXPORT Standard_Boolean GetRefDimensions (const TopoDS_Shape& theShape, 
0050                                                      XCAFDimTolObjects_DimensionObjectSequence& theDimensions) const;
0051   
0052   //! Returns a sequence of Tolerances currently stored
0053   //! in the GD&T table
0054   Standard_EXPORT void GetGeomTolerances (XCAFDimTolObjects_GeomToleranceObjectSequence& theGeomToleranceObjectSequence, 
0055                                           XCAFDimTolObjects_DatumObjectSequence& theDatumObjectSequence, 
0056                                           XCAFDimTolObjects_DataMapOfToleranceDatum& theMap) const;
0057   
0058   //! Returns all GeomTolerances defined for Shape
0059   Standard_EXPORT Standard_Boolean GetRefGeomTolerances (const TopoDS_Shape& theShape, 
0060                                                          XCAFDimTolObjects_GeomToleranceObjectSequence& theGeomToleranceObjectSequence, 
0061                                                          XCAFDimTolObjects_DatumObjectSequence& theDatumObjectSequence, 
0062                                                          XCAFDimTolObjects_DataMapOfToleranceDatum& theMap) const;
0063   
0064   //! Returns DatumObject defined for Shape
0065   Standard_EXPORT Standard_Boolean GetRefDatum (const TopoDS_Shape& theShape, 
0066                                                 Handle(XCAFDimTolObjects_DatumObject)& theDatum) const;
0067 
0068 private:
0069 
0070   Handle(XCAFDoc_DimTolTool) myDimTolTool;
0071 
0072 };
0073 
0074 #endif // _XCAFDimTolObjects_Tool_HeaderFile