X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FModelHighAPI%2FModelHighAPI_Double.cpp;h=0f0078a3a550c49afc978457bce7eb911ff14f35;hb=a13f87935d2a6f52f942790b6abc874f1016c9fc;hp=33c52647d98ef1009250ab14075a844c7f387869;hpb=bb4ab20a1f03f936d4d8511eb9e9733ee965bb72;p=modules%2Fshaper.git diff --git a/src/ModelHighAPI/ModelHighAPI_Double.cpp b/src/ModelHighAPI/ModelHighAPI_Double.cpp index 33c52647d..0f0078a3a 100644 --- a/src/ModelHighAPI/ModelHighAPI_Double.cpp +++ b/src/ModelHighAPI/ModelHighAPI_Double.cpp @@ -21,6 +21,8 @@ #include #include + +#include //-------------------------------------------------------------------------------------- //-------------------------------------------------------------------------------------- @@ -52,6 +54,16 @@ double ModelHighAPI_Double::value() const return myDouble; } +std::string ModelHighAPI_Double::string() const +{ + if (myVariantType == VT_STRING) + return myString; + + std::ostringstream anOut; + anOut << myDouble; + return anOut.str(); +} + //-------------------------------------------------------------------------------------- void ModelHighAPI_Double::fillAttribute( const std::shared_ptr & theAttribute) const