add Finder::esc(...) methods
This commit is contained in:
@@ -262,6 +262,11 @@ public:
|
||||
virtual void put_table_and_field(const wchar_t * table_name, const wchar_t * field_name, const FT & field_type);
|
||||
virtual void put_table_and_field(const pt::WTextStream & table_name, const wchar_t * field_name, const FT & field_type);
|
||||
|
||||
virtual void put_string(const char * str, const FT & field_type, bool add_quotes = false);
|
||||
virtual void put_string(const wchar_t * str, const FT & field_type, bool add_quotes = false);
|
||||
virtual void put_string(const std::string & str, const FT & field_type, bool add_quotes = false);
|
||||
virtual void put_string(const std::wstring & str, const FT & field_type, bool add_quotes = false);
|
||||
|
||||
virtual void schema_table_to_stream(pt::TextStream & stream, const wchar_t * schema_name, const wchar_t * table_name);
|
||||
virtual void schema_table_to_stream(pt::TextStream & stream, const pt::WTextStream & schema_name, const pt::WTextStream & table_name);
|
||||
virtual void table_to_stream(pt::TextStream & stream, const wchar_t * table_name);
|
||||
@@ -273,6 +278,50 @@ public:
|
||||
virtual void table_and_field_to_stream(pt::TextStream & stream, const wchar_t * table_name, const wchar_t * field_name, const FT & field_type);
|
||||
virtual void table_and_field_to_stream(pt::TextStream & stream, const pt::WTextStream & table_name, const wchar_t * field_name, const FT & field_type);
|
||||
|
||||
virtual void string_to_stream(pt::TextStream & stream, const char * str, const FT & field_type, bool add_quotes = false);
|
||||
virtual void string_to_stream(pt::TextStream & stream, const wchar_t * str, const FT & field_type, bool add_quotes = false);
|
||||
virtual void string_to_stream(pt::TextStream & stream, const std::string & str, const FT & field_type, bool add_quotes = false);
|
||||
virtual void string_to_stream(pt::TextStream & stream, const std::wstring & str, const FT & field_type, bool add_quotes = false);
|
||||
|
||||
|
||||
|
||||
template<typename StringType>
|
||||
void put_string_generic(const StringType * str, const FT & field_type, bool add_quotes)
|
||||
{
|
||||
if( out_stream )
|
||||
{
|
||||
if( add_quotes )
|
||||
{
|
||||
before_field_value_string(field_type);
|
||||
}
|
||||
|
||||
esc(str, *out_stream, field_type);
|
||||
|
||||
if( add_quotes )
|
||||
{
|
||||
after_field_value_string(field_type);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
template<typename StringType>
|
||||
void put_string_generic(const StringType & str, const FT & field_type, bool add_quotes)
|
||||
{
|
||||
if( out_stream )
|
||||
{
|
||||
if( add_quotes )
|
||||
{
|
||||
before_field_value_string(field_type);
|
||||
}
|
||||
|
||||
esc(str, *out_stream, field_type);
|
||||
|
||||
if( add_quotes )
|
||||
{
|
||||
after_field_value_string(field_type);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* IMPLEMENT ME
|
||||
|
Reference in New Issue
Block a user