Attention
This functionality is only available in the C++ toolkits. For other languages, we recommend using language-specific functionality instead.
OEStringCSVQuote¶
std::string OEStringCSVQuote(const std::string &s,
char delim=',',
char quote='"')
Returns the string s optionally surrounded by quotes,
quote, only if the delim character occurs in the string or
the first character of the string is the quote character. If
quoted, instances of the quote character in the string will be
escaped by inserting inserting another quote next to it. This
is the quoting rules as defined by RFC 4180 for the
comma-separated-value, CSV, format. This is a low-level CSV
function, most users can just use
OEStringCSVJoin and
OEStringCSVTokenize.