Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] Looking for OCaml code to load & save XML files
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2004-02-29 (17:46)
From: David MENTRE <dmentre@l...>
Subject: Re: [Caml-list] Looking for OCaml code to load & save XML files
Hello Nicolas,

"Nicolas Cannasse" <> writes:

> My advice : first experiment XmlLight and then switch to PXP if you lack
> features.

I like you advice. I've looked at your library and it's conciseness and
lack of dependencies pleases me. 

BTW, I need to save some short binary data in the XML format (e.g. MD5
128bits hash). Therefore, I would like to transform from/to an OCaml
binary string type into a string suitable for printing in an XML file
(in a CDATA field). Which code would you recommend to do that the "XML
way"?  At first sight, I intend to use Gerd's code to encode/decode MIME
and base64 strings.

As another side note, I also intend to read and write gziped XML files,
using Xavier's camlzip package. As your module uses Lexing.from_* to get
input file, I'll probably add an SFunction source type to be able to use
Lexing.from_function. In the same way, I'll probably modify your output
functions (Xml.to_string) to be able to ouput into a Gzip.out_channel
without producing the whole XML file in a string.

I'll gladly accept any advice on how to use your code,
 David Mentré <>

To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: