X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=blobdiff_plain;f=src%2FSMESH_I%2FSMESH_DumpPython.cxx;h=cc842f215462cc31dedfe6acfedeca3f84b65e55;hp=540144b665031758707107dc0fbde57aa708f044;hb=1a3a88cfc996394b2c79f2cf374c8f3c4140f036;hpb=5c5e1f2368ca2b3388f657ae028b2a6b5ce8ae36 diff --git a/src/SMESH_I/SMESH_DumpPython.cxx b/src/SMESH_I/SMESH_DumpPython.cxx index 540144b66..cc842f215 100644 --- a/src/SMESH_I/SMESH_DumpPython.cxx +++ b/src/SMESH_I/SMESH_DumpPython.cxx @@ -53,10 +53,10 @@ namespace SMESH size_t TPythonDump::myCounter = 0; const char theNotPublishedObjectName[] = "__NOT__Published__Object__"; - TVar::TVar(CORBA::Double value):myVals(1) { myVals[0] = SMESH_Comment(value); } - TVar::TVar(CORBA::Long value):myVals(1) { myVals[0] = SMESH_Comment(value); } - TVar::TVar(CORBA::Short value):myVals(1) { myVals[0] = SMESH_Comment(value); } - TVar::TVar(const SMESH::double_array& value):myVals(value.length()) + TVar::TVar(CORBA::Double value):myVals(1), myIsList(false) { myVals[0] = SMESH_Comment(value); } + TVar::TVar(CORBA::Long value):myVals(1), myIsList(false) { myVals[0] = SMESH_Comment(value); } + TVar::TVar(CORBA::Short value):myVals(1), myIsList(false) { myVals[0] = SMESH_Comment(value); } + TVar::TVar(const SMESH::double_array& value):myVals(value.length()), myIsList(true) { for ( size_t i = 0; i < value.length(); i++) myVals[i] = SMESH_Comment(value[i]); @@ -93,7 +93,7 @@ namespace SMESH operator<<(const TVar& theVarValue) { const std::vector< int >& varIDs = SMESH_Gen_i::GetSMESHGen()->GetLastParamIndices(); - if ( theVarValue.myVals.size() != 1 ) + if ( theVarValue.myIsList ) { myStream << "[ "; for ( size_t i = 1; i <= theVarValue.myVals.size(); ++i ) @@ -162,6 +162,13 @@ namespace SMESH return *this; } + TPythonDump& + TPythonDump:: + operator<<(const std::string& theArg){ + myStream< smeshBuilder.py API, "smesh" standing for SMESH_Gen + // For the conversion of IDL API calls -> smeshBuilder.py API, "smesh" standing for SMESH_Gen // was replaces with "smeshgen" (==TPythonDump::SMESHGenName()). // Change "smesh" -> "smeshgen" in the trace saved before passage to smeshBuilder.py API bool isNewVersion =