Blame | Last modification | View Log | RSS feed
#ifndef _Utilities_h#define _Utilities_h 1#include <vcl.h>#include <string>#define MASSUDWriter "MASSUDWriter"class Utilities{public:static AnsiString EscapeString( const AnsiString & value ){AnsiString result;char const *p = value.c_str();const int length = value.Length();for ( int i=0; i<length; i++ ){if ( *p == '\'' ){result += *p;}if ( *p == '\"' ){result += "\'\'";}else{result += *p;}p++;}return ( result );}static std::string EscapeString( const std::string & value ){std::string result;char const *p = value.c_str();const int length = value.length();for ( int i=0; i<length; i++ ){if ( *p == '\'' ){result += *p;}if ( *p == '\"' ){result += "\'\'";}else{result += *p;}p++;}return ( result );}};#endif // #ifndef Utilities_h