[Cppunit-devel] encoding of XmlOutputter @1.7.1-alpha
Brought to you by:
blep
|
From: FUKUDA F. <ff...@nt...> - 2002-01-18 01:36:32
|
CppUnit::XmlOutputter prints <?xml...?> at the beginning.
and it's encoding(charset) is fixed as 'ISO-8859-1'
however assertion message is NOT always English
# yes, I am a Japanese :-)
I understand it will be too heavy to support various of encodings.
so, as alternative:
class XmlOutputter {
...
std::string m_encoding;
public:
XmlOutputter( TestResult *result, std::ostream &stream, const char* encoding="ISO-8859-1" )
: m_result( result ), m_stream( stream ), m_encoding(encoding) {}
void XmlOutputter::writeProlog() {
m_stream << "<?xml version=\"1.0\" encoding='"
<< m_encoding << "' standalone='yes' ?>"
<< std::endl;
}
...
};
... how about this?
-----:-----:-----:-----:-----:-----:-----:-----:-----:-----
FUKUDA (episteme) Fumiki -- magical, but never a magic...
|