--- parser3/src/include/pa_string.h 2008/07/16 17:06:10 1.171 +++ parser3/src/include/pa_string.h 2008/07/21 07:37:02 1.174 @@ -8,7 +8,7 @@ #ifndef PA_STRING_H #define PA_STRING_H -static const char * const IDENT_STRING_H="$Date: 2008/07/16 17:06:10 $"; +static const char * const IDENT_STRING_H="$Date: 2008/07/21 07:37:02 $"; // includes #include "pa_types.h" @@ -463,7 +463,7 @@ public: /// extracts [start, finish) piece of string String& mid(size_t substr_begin, size_t substr_end) const; - String& mid(Charset& charset, size_t substr_begin, size_t substr_end) const; + String& mid(Charset& charset, size_t from, size_t to, size_t helper_length=0) const; /** ignore lang if it's L_UNSPECIFIED @@ -479,7 +479,7 @@ public: size_t this_offset=0) const { return body.pos(c, this_offset); } - size_t String::pos(Charset& charset, + size_t pos(Charset& charset, const String& substr, size_t this_offset=0, Language lang=L_UNSPECIFIED) const; @@ -519,6 +519,7 @@ public: double as_double() const { return pa_atod(cstr(), this); } int as_int() const { return pa_atoi(cstr(), this); } bool as_bool() const { return as_int()!=0; } + const String& escape(Charset& source_charset) const; private: //disabled