[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lmi] change file formats to XML
From: |
Vaclav Slavik |
Subject: |
Re: [lmi] change file formats to XML |
Date: |
Sat, 06 Mar 2010 09:35:00 +0100 |
Hi,
On Sat, 2010-03-06 at 00:16 +0000, Greg Chicares wrote:
> Explanation: for now, we still have some non-published code that uses
> the published product-file code; it writes files in the new format,
> but with the old extensions.
We could also detect XML or plain file formats based on files' content
and reuse the "old" extensions, if that's preferable.
> [Some of those files contain literal
> ampersands, which must be replaced with xml '&' entities; after
> replacement in the non-published source, we see:
> Income & Growth
> M&E
> rather than:
> Income & Growth
> M&E
> .]
I'm not sure I understand. Are you saying that the code produces invalid
XML files? Or that XML files with entities such as & are read
incorrectly? If either of these cases isn't handled by xmlwrapp
transparently, then it should be fixed.
> static void to_xml(xml::node& out, T const& in)
> {
> + out.set_content(value_cast<std::string>(in).c_str());
I avoided value_cast<> because of precision. If using numeric_io_cast<>
(which I managed to overlook somehow) is acceptable, then I'll update
the patch to use it.
Thanks,
Vaclav
- Re: [lmi] change file formats to XML, Greg Chicares, 2010/03/05
- Re: [lmi] change file formats to XML,
Vaclav Slavik <=
- Re: [lmi] change file formats to XML, Greg Chicares, 2010/03/06
- Re: [lmi] change file formats to XML, Vaclav Slavik, 2010/03/08
- Re: [lmi] change file formats to XML, Greg Chicares, 2010/03/08
- Re: [lmi] change file formats to XML, Vaclav Slavik, 2010/03/09
- Re: [lmi] change file formats to XML, Greg Chicares, 2010/03/09
- Re: [lmi] change file formats to XML, Greg Chicares, 2010/03/11
- Re: [lmi] change file formats to XML, Vaclav Slavik, 2010/03/11
- Re: [lmi] change file formats to XML, Greg Chicares, 2010/03/11