X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=blobdiff_plain;f=src%2FSMESHUtils%2FSMESH_Comment.hxx;h=c3bbe6fb58429fbda4d2c8e26428b83db024c803;hp=5e6420fda11f1dfb98d2f34f4d9612c64475893b;hb=ef3921b2afe32874a6a266ceea8a12a30cc6f17c;hpb=6bac08c1a81f34d3f21c550bd92f83654b2546a5 diff --git a/src/SMESHUtils/SMESH_Comment.hxx b/src/SMESHUtils/SMESH_Comment.hxx index 5e6420fda..c3bbe6fb5 100644 --- a/src/SMESHUtils/SMESH_Comment.hxx +++ b/src/SMESHUtils/SMESH_Comment.hxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2015 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE // // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public @@ -30,46 +30,46 @@ # include # include -using namespace std; - /*! * \brief Class to generate string from any type */ -class SMESH_Comment : public string +class SMESH_Comment : public std::string { - ostringstream _s ; + std::ostringstream _s ; public : - SMESH_Comment():string("") {} + SMESH_Comment():std::string("") {} - SMESH_Comment(const SMESH_Comment& c):string() { + SMESH_Comment(const SMESH_Comment& c):std::string() { _s << c.c_str() ; - this->string::operator=( _s.str() ); + this->std::string::operator=( _s.str() ); } SMESH_Comment & operator=(const SMESH_Comment& c) { _s << c.c_str() ; - this->string::operator=( _s.str() ); + this->std::string::operator=( _s.str() ); return *this; } template SMESH_Comment( const T &anything ) { _s << anything ; - this->string::operator=( _s.str() ); + this->std::string::operator=( _s.str() ); } template SMESH_Comment & operator<<( const T &anything ) { _s << anything ; - this->string::operator=( _s.str() ); + this->std::string::operator=( _s.str() ); return *this ; } operator char*() const { return (char*)c_str(); } + + std::ostream& Stream() { return _s; } };