Salome HOME
MeshFormatWriter and MeshFormaReader are in MEDCOUPLING namespace
[modules/smesh.git] / src / SMESHGUI / MG_ADAPT.hxx
index 2ac1f71004fc6556a0aff15f77e75980abc7cd22..379671f91ce4c602295adf5253b1e090d518087c 100644 (file)
@@ -14,9 +14,7 @@
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
 //
-// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
-
+// See http://www.salome-platform.org/
 //
 // File   : MG_ADAPT.hxx
 //
@@ -60,7 +58,10 @@ struct MgAdaptHypothesisData
 
 };
 
-
+class outFileStream : public std::ofstream{
+public:
+    ~outFileStream(){close();} //to close file at dtor
+};
 
 /*!
  * \brief Class to generate string from any type
@@ -109,7 +110,7 @@ public :
 
 class MgAdapt
 {
-    enum YesNo {YES, NO};
+
 public:
 
     MgAdapt();
@@ -211,6 +212,7 @@ public:
     static double toDbl(const std::string&, bool* isOk = 0) throw (std::invalid_argument);
     static bool toBool(const std::string&, bool* isOk = 0) throw (std::invalid_argument);
     static int toInt(const std::string&, bool* isOk = 0 ) throw (std::invalid_argument);
+    static std::string toLowerStr(const std::string& str);
 
 
     /*  default values */
@@ -308,6 +310,7 @@ private :
     std::vector< std::string> solFormatOutput;
     std::vector <group> groupVec;
     std::vector <family> famVec;
+    std::vector< std::string> tmpFilesToBeDeleted;
 
     /* convert MED-->.mesh format */
     void convertMedFile(std::string& meshIn,std::string& solFileIn,  std::string& sizeMapIn)  ;
@@ -325,6 +328,8 @@ private :
     med_idt openMedFile(const std::string aFile) ;
     bool isFileExist(std::string& fName) const;
     void execCmd( const char* cmd, int& err);
+    void cleanUp();
+    void appendMsgToLogFile(std::string& msg);
 };