From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=AWL autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail1-relais-roc.national.inria.fr (mail1-relais-roc.national.inria.fr [192.134.164.82]) by yquem.inria.fr (Postfix) with ESMTP id EADF3BC6C for ; Tue, 5 Feb 2008 06:08:01 +0100 (CET) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AgAAAMJ9p0fUGyodimdsb2JhbACQNAEBAQgCCAcKCAkHgRSaXw X-IronPort-AV: E=Sophos;i="4.25,304,1199660400"; d="scan'208";a="7593509" Received: from smtp3-g19.free.fr ([212.27.42.29]) by mail1-smtp-roc.national.inria.fr with ESMTP; 05 Feb 2008 06:08:01 +0100 Received: from smtp3-g19.free.fr (localhost.localdomain [127.0.0.1]) by smtp3-g19.free.fr (Postfix) with ESMTP id 5867C17B52C; Tue, 5 Feb 2008 06:08:01 +0100 (CET) Received: from [192.168.0.3] (rke75-3-82-229-183-156.fbx.proxad.net [82.229.183.156]) by smtp3-g19.free.fr (Postfix) with ESMTP id 2B9B817B52B; Tue, 5 Feb 2008 06:08:01 +0100 (CET) Message-ID: <47A7EDFE.1050805@frisch.fr> Date: Tue, 05 Feb 2008 06:02:54 +0100 From: Alain Frisch User-Agent: Thunderbird 2.0.0.9 (Windows/20071031) MIME-Version: 1.0 To: Jim Miller Cc: caml-list@yquem.inria.fr Subject: Re: [Caml-list] [OSR] Suggested topic - XML processing API References: <52FAAA41-5B70-4F87-9F83-B8A96EA48D34@erratique.ch> <200801301035.31447.jon@ffconsultancy.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam: no; 0.00; frisch:01 frisch:01 namespaces:01 parser:01 nodes:01 'pull':01 parser:01 tokens:01 sax-like:01 'push':01 libs:01 variants:01 polymorphic:01 wrote:01 parsing:01 Jim Miller wrote: > I await suggestions/flames. As suggested before, you really need to say something, at least, about: - namespaces (including for attributes): the most acceptable solution is probably to do nothing about them and remove the first argument to the XmlElement constructor; - encoding of strings in the internal representation: probably always utf-8; - whether the parser may create XmlMany nodes: probably no. Other remarks: - a 'pull' API (where the client asks the parser for more parsing events/tokens) is more convenient than the SAX-like 'push' API. You might want to add such an API to you spec; - having a common spec for several libs makes more sense if they can share common types; maybe you should use polymorphic variants instead of regular ones? -- Alain