Back to home page

EIC code displayed by LXR

 
 

    


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

0001 // Created on: 1994-10-03
0002 // Created by: Christian CAILLET
0003 // Copyright (c) 1994-1999 Matra Datavision
0004 // Copyright (c) 1999-2014 OPEN CASCADE SAS
0005 //
0006 // This file is part of Open CASCADE Technology software library.
0007 //
0008 // This library is free software; you can redistribute it and/or modify it under
0009 // the terms of the GNU Lesser General Public License version 2.1 as published
0010 // by the Free Software Foundation, with special exception defined in the file
0011 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0012 // distribution for complete text of the license and disclaimer of any warranty.
0013 //
0014 // Alternatively, this file may be used under the terms of Open CASCADE
0015 // commercial license or contractual agreement.
0016 
0017 #ifndef _TransferBRep_ShapeListBinder_HeaderFile
0018 #define _TransferBRep_ShapeListBinder_HeaderFile
0019 
0020 #include <Standard.hxx>
0021 #include <Standard_Type.hxx>
0022 
0023 #include <TopTools_HSequenceOfShape.hxx>
0024 #include <Transfer_Binder.hxx>
0025 #include <Standard_Integer.hxx>
0026 #include <TopAbs_ShapeEnum.hxx>
0027 class TopoDS_Shape;
0028 class TopoDS_Vertex;
0029 class TopoDS_Edge;
0030 class TopoDS_Wire;
0031 class TopoDS_Face;
0032 class TopoDS_Shell;
0033 class TopoDS_Solid;
0034 class TopoDS_CompSolid;
0035 class TopoDS_Compound;
0036 
0037 
0038 class TransferBRep_ShapeListBinder;
0039 DEFINE_STANDARD_HANDLE(TransferBRep_ShapeListBinder, Transfer_Binder)
0040 
0041 //! This binder binds several (a list of) shapes with a starting
0042 //! entity, when this entity itself corresponds to a simple list
0043 //! of shapes. Each part is not seen as a sub-result of an
0044 //! independent component, but as an item of a built-in list
0045 class TransferBRep_ShapeListBinder : public Transfer_Binder
0046 {
0047 
0048 public:
0049 
0050   
0051   Standard_EXPORT TransferBRep_ShapeListBinder();
0052   
0053   Standard_EXPORT TransferBRep_ShapeListBinder(const Handle(TopTools_HSequenceOfShape)& list);
0054   
0055   Standard_EXPORT virtual Standard_Boolean IsMultiple() const Standard_OVERRIDE;
0056   
0057   Standard_EXPORT Handle(Standard_Type) ResultType() const Standard_OVERRIDE;
0058   
0059   Standard_EXPORT Standard_CString ResultTypeName() const Standard_OVERRIDE;
0060   
0061   //! Adds an item to the result list
0062   Standard_EXPORT void AddResult (const TopoDS_Shape& res);
0063   
0064   Standard_EXPORT Handle(TopTools_HSequenceOfShape) Result() const;
0065   
0066   //! Changes an already defined sub-result
0067   Standard_EXPORT void SetResult (const Standard_Integer num, const TopoDS_Shape& res);
0068   
0069   Standard_EXPORT Standard_Integer NbShapes() const;
0070   
0071   Standard_EXPORT const TopoDS_Shape& Shape (const Standard_Integer num) const;
0072   
0073   Standard_EXPORT TopAbs_ShapeEnum ShapeType (const Standard_Integer num) const;
0074   
0075   Standard_EXPORT TopoDS_Vertex Vertex (const Standard_Integer num) const;
0076   
0077   Standard_EXPORT TopoDS_Edge Edge (const Standard_Integer num) const;
0078   
0079   Standard_EXPORT TopoDS_Wire Wire (const Standard_Integer num) const;
0080   
0081   Standard_EXPORT TopoDS_Face Face (const Standard_Integer num) const;
0082   
0083   Standard_EXPORT TopoDS_Shell Shell (const Standard_Integer num) const;
0084   
0085   Standard_EXPORT TopoDS_Solid Solid (const Standard_Integer num) const;
0086   
0087   Standard_EXPORT TopoDS_CompSolid CompSolid (const Standard_Integer num) const;
0088   
0089   Standard_EXPORT TopoDS_Compound Compound (const Standard_Integer num) const;
0090 
0091 
0092 
0093 
0094   DEFINE_STANDARD_RTTIEXT(TransferBRep_ShapeListBinder,Transfer_Binder)
0095 
0096 protected:
0097 
0098 
0099 
0100 
0101 private:
0102 
0103 
0104   Handle(TopTools_HSequenceOfShape) theres;
0105 
0106 
0107 };
0108 
0109 
0110 
0111 
0112 
0113 
0114 
0115 #endif // _TransferBRep_ShapeListBinder_HeaderFile