Salome HOME
Issue #608: Usage of OCCT in interface -- Remove OCCT from *Import interfaces
[modules/shaper.git] / src / GeomAlgoAPI / GeomAlgoAPI_IGESImport.cpp
index 8e20cb32aec65b37fb6cbe8b2551efb1605bdeaa..b15b0d19e63504d4b020190d94298d1531b657b7 100644 (file)
  *
  */
 //=============================================================================
-//extern "C" {
 namespace IGESImport {
-TopoDS_Shape Import(const TCollection_AsciiString& theFileName,
-                    const TCollection_AsciiString&,
-                    TCollection_AsciiString& theError)
+
+TopoDS_Shape Import(const std::string& theFileName,
+                    const std::string&,
+                    std::string& theError)
 {
   #ifdef _DEBUG
   std::cout << "Import IGES from file " << theFileName << std::endl;
@@ -23,7 +23,7 @@ TopoDS_Shape Import(const TCollection_AsciiString& theFileName,
   TopoDS_Shape aResShape;
   IGESControl_Reader aReader;
   try {
-    IFSelect_ReturnStatus status = aReader.ReadFile( theFileName.ToCString() );
+    IFSelect_ReturnStatus status = aReader.ReadFile( theFileName.c_str() );
 
     if (status == IFSelect_RetDone) {
       #ifdef _DEBUG
@@ -67,5 +67,4 @@ TopoDS_Shape Import(const TCollection_AsciiString& theFileName,
   return aResShape;
 }
 
-}
-//}
+} // namespace IGESImport