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]);
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 )
return *this;
}
+ TPythonDump&
+ TPythonDump::
+ operator<<(const std::string& theArg){
+ myStream<<theArg;
+ return *this;
+ }
+
TPythonDump&
TPythonDump::
operator<<(const SMESH::ElementType& theArg)
case Entity_TriQuad_Hexa: myStream<<"Entity_TriQuad_Hexa"; break;
case Entity_Penta: myStream<<"Entity_Penta"; break;
case Entity_Quad_Penta: myStream<<"Entity_Quad_Penta"; break;
+ case Entity_BiQuad_Penta: myStream<<"Entity_BiQuad_Penta"; break;
case Entity_Hexagonal_Prism: myStream<<"Entity_Hexagonal_Prism"; break;
case Entity_Polyhedra: myStream<<"Entity_Polyhedra"; break;
case Entity_Quad_Polyhedra: myStream<<"Entity_Quad_Polyhedra"; break;
case FT_MultiConnection2D: myStream<< "aMultiConnection2D"; break;
case FT_Length: myStream<< "aLength"; break;
case FT_Length2D: myStream<< "aLength2D"; break;
+ case FT_Deflection2D: myStream<< "aDeflection2D"; break;
case FT_NodeConnectivityNumber:myStream<< "aNodeConnectivityNumber";break;
case FT_BelongToMeshGroup: myStream<< "aBelongToMeshGroup"; break;
case FT_BelongToGeom: myStream<< "aBelongToGeom"; break;
switch (theVersion) {
case SMESH::MED_V2_1: myStream << "SMESH.MED_V2_1"; break;
case SMESH::MED_V2_2: myStream << "SMESH.MED_V2_2"; break;
+ case SMESH::MED_LATEST: myStream << "SMESH.MED_LATEST"; break;
+ case SMESH::MED_MINOR_0: myStream << "SMESH.MED_MINOR_0"; break;
+ case SMESH::MED_MINOR_1: myStream << "SMESH.MED_MINOR_1"; break;
+ case SMESH::MED_MINOR_2: myStream << "SMESH.MED_MINOR_2"; break;
+ case SMESH::MED_MINOR_3: myStream << "SMESH.MED_MINOR_3"; break;
+ case SMESH::MED_MINOR_4: myStream << "SMESH.MED_MINOR_4"; break;
+ case SMESH::MED_MINOR_5: myStream << "SMESH.MED_MINOR_5"; break;
+ case SMESH::MED_MINOR_6: myStream << "SMESH.MED_MINOR_6"; break;
+ case SMESH::MED_MINOR_7: myStream << "SMESH.MED_MINOR_7"; break;
+ case SMESH::MED_MINOR_8: myStream << "SMESH.MED_MINOR_8"; break;
+ case SMESH::MED_MINOR_9: myStream << "SMESH.MED_MINOR_9"; break;
default: myStream << theVersion;
}
return *this;
lines.push_back( theSavedTrace.SubString( from, to - 1 ));
from = to + 1;
}
- // For the convertion of IDL API calls -> 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 =
{
// find the function name
int functBeg = posAlready;
- char* script = (char*) anUpdatedScript.ToCString() + posAlready - 1; // look at ":" after "def fuction()"
+ char* script = (char*) anUpdatedScript.ToCString() + posAlready - 1; // look at ":" after "def function()"
while ( *script != ' ' ) {
script--;
functBeg--;