Read the FAQ. Go through all of the sample programs and carefully look at
what they do. Read up on the DOM and SAX APIs which are publically defined
APIs that the Xerces parser implements, so they are well documented
elsewhere. Since they are the most common ways to use the parser, you'll get
a lot out of that study.

As to the archives being old, I wouldn't stress too much if you are new to
it. The most common problems happen over and over and over again and have
been answered many times over, so they should get plenty of coverage.

There is currently no 'single API' to re-serialize the XML. For now, just
steal the code in DOMPrint and manipulate it to your needs.

If you want to use the same DTD over and over, then just do an initial parse
on a dummy file that references the DTD. After that, set the reuseValidator
parameter to true, which will cause it to reuse that DTD information again.
But you cannot have any internal DTD subset in the files being parsed if you
do this.

As far as keeping the DTD in memory, you can do that too, so that you do the
initial parse of it from an in-memory copy. The techniques required to do
this are a combination of those shown in the MemParse and Redirect samples.

--------------
Dean Roddey
Software Geek Extraordinaire
Portal, Inc
[EMAIL PROTECTED]



-----Original Message-----
From: Charles Prosser [mailto:[EMAIL PROTECTED]]
Sent: Monday, April 02, 2001 9:08 AM
To: [EMAIL PROTECTED]
Subject: new to xerces xml



Hello,

I am new to xml and xerces-c.  I support an api which sends requests and
receives replies
in the form of a data structure sent via tcp/ip sockets.  I plan on
converting this api so that
requests and replies are sent in xml format.  I have a few questions:

1.  What is the best way to get started on familiarizing myself with xml
and xerces-c?
     Where is there a good tutorial on xml?

2.  How can I best use the mailing list?  It appears the archives are two
months behind.  I'm not
     sure I can wade through all the e-mail that arrives if I'm directly
subscribed.

3.  I have looked at some of the samples.  To build the xml message I'm
guessing my code will
     create a DOM tree in memory similar to what is done in
CreateDomDocument.cpp.  How do I
     then convert the in-core DOM tree to xml to be sent via socket?

4. I have created a DTD which defines the format of all messages to be
exchanged.  Is there some way
    of verifying that the xml I create conforms to the format defined in
the DTD?  Can the DTD reside
     in the source code where the xml is created?  I don't want to send it
along with every request/reply.

5.  In order to parse an xml message received I'm guessing I'm going to use
code similar to DOMPrint.cpp,
     using MemBufInputSource to parse from a buffer instead of a file?

6.  Same as question 4.  How to I verify that the xml message parsed
conforms to the DTD I created?
     Can the DTD reside in the source code which is processing this
message?

Thanks for help with these beginner questions.  Please point me to archive
threads if these have
already been exhaustively covered.


Charles Prosser


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to