mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2024-11-15 10:08:34 +05:00
Kernel_Utils::Localizer - common interface to solve problems with non-"C" locales
This commit is contained in:
parent
905b855999
commit
f17fbdcfdb
@ -26,10 +26,13 @@
|
||||
|
||||
#include "utilities.h"
|
||||
|
||||
#include <Basics_Utils.hxx>
|
||||
|
||||
using namespace std;
|
||||
|
||||
Driver_Mesh::Status DriverDAT_R_SMDS_Mesh::Perform()
|
||||
{
|
||||
Kernel_Utils::Localizer loc;
|
||||
Status aResult = DRS_OK;
|
||||
|
||||
int i, j;
|
||||
|
@ -27,10 +27,13 @@
|
||||
|
||||
#include "utilities.h"
|
||||
|
||||
#include <Basics_Utils.hxx>
|
||||
|
||||
using namespace std;
|
||||
|
||||
Driver_Mesh::Status DriverDAT_W_SMDS_Mesh::Perform()
|
||||
{
|
||||
Kernel_Utils::Localizer loc;
|
||||
Status aResult = DRS_OK;
|
||||
|
||||
int nbNodes, nbCells;
|
||||
|
@ -30,6 +30,8 @@
|
||||
#include "UNV2417_Structure.hxx"
|
||||
#include "UNV_Utilities.hxx"
|
||||
|
||||
#include <Basics_Utils.hxx>
|
||||
|
||||
using namespace std;
|
||||
|
||||
|
||||
@ -49,7 +51,7 @@ DriverUNV_R_SMDS_Mesh::~DriverUNV_R_SMDS_Mesh()
|
||||
|
||||
Driver_Mesh::Status DriverUNV_R_SMDS_Mesh::Perform()
|
||||
{
|
||||
UNV::Localizer loc;
|
||||
Kernel_Utils::Localizer loc;
|
||||
Status aResult = DRS_OK;
|
||||
std::ifstream in_stream(myFile.c_str());
|
||||
try{
|
||||
|
@ -36,6 +36,8 @@
|
||||
#include "UNV2417_Structure.hxx"
|
||||
#include "UNV_Utilities.hxx"
|
||||
|
||||
#include <Basics_Utils.hxx>
|
||||
|
||||
using namespace std;
|
||||
using namespace UNV;
|
||||
|
||||
@ -57,7 +59,7 @@ namespace{
|
||||
|
||||
Driver_Mesh::Status DriverUNV_W_SMDS_Mesh::Perform()
|
||||
{
|
||||
UNV::Localizer loc;
|
||||
Kernel_Utils::Localizer loc;
|
||||
Status aResult = DRS_OK;
|
||||
std::ofstream out_stream(myFile.c_str());
|
||||
try{
|
||||
|
@ -35,22 +35,6 @@
|
||||
namespace UNV{
|
||||
using namespace std;
|
||||
|
||||
class MESHDRIVERUNV_EXPORT Localizer
|
||||
{
|
||||
public:
|
||||
Localizer()
|
||||
{
|
||||
myCurLocale = setlocale(LC_NUMERIC, 0);
|
||||
setlocale(LC_NUMERIC, "C");
|
||||
}
|
||||
~Localizer()
|
||||
{
|
||||
setlocale(LC_NUMERIC, myCurLocale.c_str());
|
||||
}
|
||||
private:
|
||||
std::string myCurLocale;
|
||||
};
|
||||
|
||||
class MESHDRIVERUNV_EXPORT PrefixPrinter{
|
||||
static int myCounter;
|
||||
public:
|
||||
|
Loading…
Reference in New Issue
Block a user