File indexing completed on 2026-09-15 09:16:59
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016 #ifndef _ShapeProcess_ShapeContext_HeaderFile
0017 #define _ShapeProcess_ShapeContext_HeaderFile
0018
0019 #include <Standard.hxx>
0020 #include <Standard_Type.hxx>
0021
0022 #include <TopoDS_Shape.hxx>
0023 #include <TopTools_ShapeMapHasher.hxx>
0024 #include <NCollection_DataMap.hxx>
0025 #include <TopAbs_ShapeEnum.hxx>
0026 #include <ShapeProcess_Context.hxx>
0027 #include <Message_Gravity.hxx>
0028 #include <GeomAbs_Shape.hxx>
0029 class ShapeExtend_MsgRegistrator;
0030 class ShapeBuild_ReShape;
0031 class BRepTools_Modifier;
0032 class Message_Msg;
0033
0034
0035
0036
0037 class ShapeProcess_ShapeContext : public ShapeProcess_Context
0038 {
0039
0040 public:
0041 Standard_EXPORT ShapeProcess_ShapeContext(const char* const file, const char* const seq = "");
0042
0043
0044
0045 Standard_EXPORT ShapeProcess_ShapeContext(const TopoDS_Shape& S,
0046 const char* const file,
0047 const char* const seq = "");
0048
0049
0050 Standard_EXPORT void Init(const TopoDS_Shape& S);
0051
0052
0053 Standard_EXPORT const TopoDS_Shape& Shape() const;
0054
0055
0056 Standard_EXPORT const TopoDS_Shape& Result() const;
0057
0058
0059
0060 Standard_EXPORT const NCollection_DataMap<TopoDS_Shape, TopoDS_Shape, TopTools_ShapeMapHasher>&
0061 Map() const;
0062
0063 Standard_EXPORT const occ::handle<ShapeExtend_MsgRegistrator>& Messages() const;
0064
0065
0066
0067
0068 Standard_EXPORT occ::handle<ShapeExtend_MsgRegistrator>& Messages();
0069
0070 Standard_EXPORT void SetDetalisation(const TopAbs_ShapeEnum level);
0071
0072
0073
0074
0075
0076
0077
0078 Standard_EXPORT TopAbs_ShapeEnum GetDetalisation() const;
0079
0080
0081
0082
0083
0084
0085
0086 Standard_EXPORT void SetResult(const TopoDS_Shape& S);
0087
0088 Standard_EXPORT void RecordModification(
0089 const NCollection_DataMap<TopoDS_Shape, TopoDS_Shape, TopTools_ShapeMapHasher>& repl,
0090 const occ::handle<ShapeExtend_MsgRegistrator>& msg = nullptr);
0091
0092 Standard_EXPORT void RecordModification(const occ::handle<ShapeBuild_ReShape>& repl,
0093 const occ::handle<ShapeExtend_MsgRegistrator>& msg);
0094
0095 Standard_EXPORT void RecordModification(const occ::handle<ShapeBuild_ReShape>& repl);
0096
0097
0098
0099
0100
0101
0102
0103
0104
0105
0106
0107 Standard_EXPORT void RecordModification(
0108 const TopoDS_Shape& sh,
0109 const BRepTools_Modifier& repl,
0110 const occ::handle<ShapeExtend_MsgRegistrator>& msg = nullptr);
0111
0112
0113
0114
0115
0116 Standard_EXPORT void AddMessage(const TopoDS_Shape& S,
0117 const Message_Msg& msg,
0118 const Message_Gravity gravity = Message_Warning);
0119
0120
0121
0122 Standard_EXPORT bool GetContinuity(const char* const param, GeomAbs_Shape& val) const;
0123
0124
0125
0126
0127 Standard_EXPORT GeomAbs_Shape ContinuityVal(const char* const param,
0128 const GeomAbs_Shape def) const;
0129
0130
0131 Standard_EXPORT void PrintStatistics() const;
0132
0133
0134 void SetNonManifold(bool theNonManifold) { myNonManifold = theNonManifold; }
0135
0136
0137 bool IsNonManifold() { return myNonManifold; }
0138
0139 DEFINE_STANDARD_RTTIEXT(ShapeProcess_ShapeContext, ShapeProcess_Context)
0140
0141 private:
0142 TopoDS_Shape myShape;
0143 TopoDS_Shape myResult;
0144 NCollection_DataMap<TopoDS_Shape, TopoDS_Shape, TopTools_ShapeMapHasher> myMap;
0145 occ::handle<ShapeExtend_MsgRegistrator> myMsg;
0146 TopAbs_ShapeEnum myUntil;
0147 bool myNonManifold;
0148 };
0149
0150 #endif