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=none autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by yquem.inria.fr (Postfix) with ESMTP id 3F574BC6C for ; Wed, 30 Jan 2008 16:55:27 +0100 (CET) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AgAAAKMsoEfAXQInh2dsb2JhbACQJwEBAQgKKZ8o X-IronPort-AV: E=Sophos;i="4.25,277,1199660400"; d="scan'208";a="8542585" Received: from concorde.inria.fr ([192.93.2.39]) by mail3-smtp-sop.national.inria.fr with ESMTP; 30 Jan 2008 16:55:26 +0100 Received: from mail1-relais-roc.national.inria.fr (mail1-relais-roc.national.inria.fr [192.134.164.82]) by concorde.inria.fr (8.13.6/8.13.6) with ESMTP id m0UFtQVn004249 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=OK) for ; Wed, 30 Jan 2008 16:55:26 +0100 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ao8CAOcsoEfUVZgL/2dsb2JhbACwDQ X-IronPort-AV: E=Sophos;i="4.25,277,1199660400"; d="scan'208";a="7436076" Received: from hades.snarc.org ([212.85.152.11]) by mail1-smtp-roc.national.inria.fr with ESMTP; 30 Jan 2008 16:55:26 +0100 Received: by hades.snarc.org (Postfix, from userid 1000) id 073421B482; Wed, 30 Jan 2008 16:55:19 +0100 (CET) Date: Wed, 30 Jan 2008 16:55:18 +0100 To: =?iso-8859-1?Q?B=FCnzli?= Daniel Cc: caml-list List Subject: Re: [Caml-list] [OSR] Suggested topic - XML processing API Message-ID: <20080130155518.GA9526@snarc.org> References: <52FAAA41-5B70-4F87-9F83-B8A96EA48D34@erratique.ch> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <52FAAA41-5B70-4F87-9F83-B8A96EA48D34@erratique.ch> X-Warning: Email may contain unsmilyfied humor and/or satire. User-Agent: Mutt/1.5.16 (2007-06-11) From: tab@snarc.org (Vincent Hanquez) X-Miltered: at concorde with ID 47A09DEE.000 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; 0100,:01 bunzli:01 wiki:01 parsers:01 datatype:01 parsers:01 parser:01 parser:01 wrote:01 partial:01 abstract:01 abstract:01 signatures:01 parsing:01 parsing:01 On Wed, Jan 30, 2008 at 03:37:59AM +0100, Bünzli Daniel wrote: > > Le 30 janv. 08 à 01:54, Jim Miller a écrit : > >> Inspired by the existing recommendation on the cocan wiki for I/O, I'd >> like to recommend the development of a standard interface for XML >> processing. Currently there are many different implementations of XML >> parsers but their interfaces are very different and don't allow for easy >> swapping of implementations. > > There are many approaches to xml parsing (partial implementations, > leniency, well-formedness, validity, etc.), to parsing results (tree, > custom data structure, stream, namespace support etc.) and to processing > (mainly dependent on the parsing result). Xml processing cannot be seen as > an abstract datatype with different implementations, there are different > ways. > > As such I'm not sure such an interface is really feasible. Now if you see a > common pattern or concrete type signatures that could be changed to make > parsers more compatible do not hesitate to communicate them. If it benefits > the users of my parser and remains in its philosophy I'll happily implement > them. But _you_ have to make concrete proposal, I'm not going to research > this. Please do not just initiate a discussion because you like the > abstract idea of being able to swap xml parser implementations, make > proposals. a do-everything interface is absolutely impossible, but providing a "simple" library that parse DOM and SAX style to fill _common_ needs, is relatively "easy". For people that got specifics needs, there's nothing preventing them to implement/use a side library without using the common distributed library. -- Vincent Hanquez