Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027 #ifndef ShHealOper_ShapeProcess_HeaderFile
00028 #define ShHealOper_ShapeProcess_HeaderFile
00029
00030 #include <Resource_Manager.hxx>
00031 #include <TopoDS_Shape.hxx>
00032 #include <TopTools_DataMapOfShapeShape.hxx>
00033 #include <TColStd_SequenceOfAsciiString.hxx>
00034 #include <TCollection_AsciiString.hxx>
00035 #include <ShapeProcessAPI_ApplySequence.hxx>
00036 #include <ShapeProcess_ShapeContext.hxx>
00037
00039
00040
00041 class ShHealOper_ShapeProcess
00042 {
00043 public:
00044
00045
00047 Standard_EXPORT ShHealOper_ShapeProcess();
00048
00049
00050
00051
00053 Standard_EXPORT ShHealOper_ShapeProcess
00054 (const TCollection_AsciiString& theNameResource,
00055 const TCollection_AsciiString& thePrefix = "ShapeProcess");
00056
00057
00058 Standard_EXPORT void Perform(const TopoDS_Shape& theOldShape,
00059 TopoDS_Shape& theNewShape);
00060
00061
00062 Standard_EXPORT void SetOperators(const TColStd_SequenceOfAsciiString& theSeqOperators);
00063
00064
00065 Standard_EXPORT Standard_Boolean GetOperators(TColStd_SequenceOfAsciiString& theSeqOperators);
00066
00067
00068 Standard_EXPORT void SetParameter(const TCollection_AsciiString& theNameParam,
00069 const TCollection_AsciiString& theVal);
00070
00071
00072 Standard_EXPORT Standard_Boolean GetParameter(const TCollection_AsciiString& theNameParam,
00073 TCollection_AsciiString& theVal);
00074
00075
00076 inline void SetSaveHistoryMode(const Standard_Boolean theSaveHistory,
00077 TopAbs_ShapeEnum theuntil = TopAbs_FACE)
00078 {
00079 mySaveHistoryMode = theSaveHistory;
00080 myLevel = theuntil;
00081 }
00082
00083
00084
00085
00086 inline Standard_Boolean GetSaveHistoryMode()
00087 {
00088 return mySaveHistoryMode;
00089 }
00090
00091
00092 inline Standard_Boolean GetModifiedShape(const TopoDS_Shape& theOldShape,
00093 TopoDS_Shape& theNewShape)
00094 {
00095 Standard_Boolean isModif = (!myMapModifications.IsEmpty() &&
00096 myMapModifications.IsBound(theOldShape));
00097 if(isModif)
00098 theNewShape = myMapModifications.Find(theOldShape);
00099 else
00100 theNewShape = theOldShape;
00101 return isModif;
00102 }
00103
00104
00105 inline Standard_Boolean isDone()
00106 {
00107 return myDone;
00108 }
00109
00110 protected:
00111
00112
00113
00114
00115 private:
00116
00117
00118
00119 ShapeProcessAPI_ApplySequence myOperations;
00120 TCollection_AsciiString myPrefix;
00121 TopTools_DataMapOfShapeShape myMapModifications;
00122 Standard_Boolean mySaveHistoryMode;
00123 TopAbs_ShapeEnum myLevel;
00124 Standard_Boolean myDone;
00125 public:
00126
00127
00128 };
00129
00130
00131
00132
00133
00134 #endif