473,386 Members | 1,804 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Want to Validate a DOM Tree Against a Schema - Xerces C/C++

I would like to perform a schema validation of a DOM tree that is
already assembled in memory with as little fuss and setup as possible.

I see support in the Xerces documentation to perform validation with
DOMBuilder and XercesDOMParser. There is also an interface class
called XMLValidator, but it is not clear to me how I might use these
resources to achieve what I described above. Any help getting started
in the right direction would be greatly appreciated.

Thanks in advance

Sep 14 '05 #1
1 2209
Novitas wrote:
I would like to perform a schema validation of a DOM tree that is
already assembled in memory with as little fuss and setup as possible.

I see support in the Xerces documentation to perform validation with
DOMBuilder and XercesDOMParser. There is also an interface class
called XMLValidator, but it is not clear to me how I might use these
resources to achieve what I described above. Any help getting started
in the right direction would be greatly appreciated.


In Java, one uses a SchemaFactory to create a Schema, and then one uses
that schema to create a Validator. Finally, a DOMSource is created from
the DOM tree and passed to the Validator.

I'm not sure how much of this will translate to C/C++, but it might get
you started in the right direction.

HTH

--
================================================== ======================
Ian Pilcher i.*******@comcast.net
================================================== ======================
Sep 14 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Fu Bo Xia | last post by:
anyone know a Java (or Java usable) package that converts XML Schema (XSD) documents into a tree form? thanks, fu bo
4
by: joes | last post by:
Hello there I tried for several days to get a simple validation with xml schema & xerces working. Goal for me is tuse JAXP and not specific Xerces classes. I don't get the point what I am doing...
9
by: Leona | last post by:
Hello all, does anyone know of a tool, preferably free, preferably on linux, which will take an xml file and validate it against your own custom W3C XML Schema file (.xsd) ?? All help...
1
by: QuantDev | last post by:
Hi NG, I would need to validate an XML fragment against a type defined within an XSD (which defines many other things). What is the correct way of achieving this? QD2004
7
by: Georg J. Stach | last post by:
Hi, as mentioned above I'd like to validate a simple XML-document with a simple DTD. For this, I use Java and Xerces. But, when I have tags of this form: <tag>some characters in here</tag> ...
1
by: Ron Rohrssen | last post by:
I've been working on learning XML schemas and trying to make use of the MS classes for validating data against a schema. So, I've been trying to work through some simple schemas and instances....
3
by: ciaran.mchale | last post by:
Hi folks, I downloaded the binary version of Xerces C++ 2.7.0 for Windows and am using it to help me get up to speed with XML and XML Schema. So please excuse me if this is a "novice" question....
8
by: pradeepsarathy | last post by:
Hi all, Does the SAX parser has eventhandlers for parsing xml schema. Can we parse the xml schema the same way as we parse the xml document using SAX Parser. Thanks in advance. -pradeep
2
by: sk | last post by:
http://java.sun.com/developer/technicalArticles/xml/validationxpath/index.html I am following this sample and trying to learn how to validate xml document with the schema I am getting the...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.