X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FModelHighAPI%2FModelHighAPI_Double.cpp;h=0f0078a3a550c49afc978457bce7eb911ff14f35;hb=a13f87935d2a6f52f942790b6abc874f1016c9fc;hp=35370c8190295fb7bcbdc02229ce90c1c06dafd6;hpb=6e421e939851e0de46554ae45a3ca0e1f67cd91d;p=modules%2Fshaper.git diff --git a/src/ModelHighAPI/ModelHighAPI_Double.cpp b/src/ModelHighAPI/ModelHighAPI_Double.cpp index 35370c819..0f0078a3a 100644 --- a/src/ModelHighAPI/ModelHighAPI_Double.cpp +++ b/src/ModelHighAPI/ModelHighAPI_Double.cpp @@ -21,6 +21,8 @@ #include #include + +#include //-------------------------------------------------------------------------------------- //-------------------------------------------------------------------------------------- @@ -46,6 +48,22 @@ ModelHighAPI_Double::~ModelHighAPI_Double() { } +double ModelHighAPI_Double::value() const +{ + // needed for array of double, which supports no text + 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