Re: [libxml++] Schema validation with libxml++



Hello,

Thanks for the reply. I've finally write my own patch, but for gdome2.
My patch does schema validation against schema file name given in attribute

Namespace:http:://www.w3.org/2001/XMLSchema-instance
Localname:schemaLocation

Of the root node of the document.

(It uses of course libxml2).

Regards.

Laurent Marzullo
New Convergence Program
Core Solution Delivery & Industrialization 
Tel:  +33 (0) 1 44 44 55 54 
Site: Losserand - Office n° 1059
lmarzullo externe orange-ftgroup com
-----Message d'origine-----
De : Murray Cumming [mailto:murrayc murrayc com] 
Envoyé : dimanche 10 juin 2007 19:24
À : MARZULLO Laurent Ext DF/DCGC
Cc : libxmlplusplus-general lists sourceforge net
Objet : Re: [libxml++] Schema validation with libxml++

On Wed, 2007-06-06 at 14:28 +0200, MARZULLO Laurent Ext DF/DCGC wrote:

> I would like to know how to validate an XML file with a schema with
libxml++-2.12
>
> I?ve found something like with ?libxml2?:
>             xmlTextReaderPtr         reader;
>             xmlTextReaderSchemaValidate( reader , schema );
> But could not found any example on how to use schema validation with
libxml++.

Sorry, I don't think that libxml++ supports Schema validation yet.

There is a patch in bugzilla for this, but I'm not sure if it's the
right approach:
http://bugzilla.gnome.org/show_bug.cgi?id=312216

Isn't the Schema just named in the XML file, instead of a DTD file? If
so, I would expect the validation to happen (optionally) when parsing
the document, as we do for DTD-based XML files.

-- 
Murray Cumming
murrayc murrayc com
www.murrayc.com
www.openismus.com


*********************************
This message and any attachments (the "message") are confidential and intended solely for the addressees. 
Any unauthorised use or dissemination is prohibited.
Messages are susceptible to alteration. 
France Telecom Group shall not be liable for the message if altered, changed or falsified.
If you are not the intended addressee of this message, please cancel it immediately and inform the sender.
********************************




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]