Click here to Skip to main content
Click here to Skip to main content

XML Reading Using DOM and SAX

By , 10 Aug 2002
 
There are two simple methods in my application: one is reading xml file by using DOM method and the other is reading the same file using SAX method. I’m not gonna explain the difference between DOM & SAX, only telling this that in DOM , a parser must read the whole file u r reading before u can read anything. In other words the file is loaded into the memory of your application, where DOM makes an object model of it, then u can traverse throw the elements of this object model & receive/update needed information. SAX method, reads file step by step, so it is a resource benefit . Of course there can be said a lot about that but if u r interested I’m sure u’ll find more complex info. I made this example when I was studying XML and its two models/interfaces for making parsers – DOM & SAX and it was interesting for me to use them throw NET.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here

About the Author

rosen
Web Developer
Bulgaria Bulgaria
Member
No Biography provided

Sign Up to vote   Poor Excellent
Add a reason or comment to your vote: x
Votes of 3 or less require a comment

Comments and Discussions

 
Hint: For improved responsiveness ensure Javascript is enabled and choose 'Normal' from the Layout dropdown and hit 'Update'.
You must Sign In to use this message board.
Search this forum  
    Spacing  Noise  Layout  Per page   
Questionwhere is SAX?membertheGrim11 Oct '06 - 6:25 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Permalink | Advertise | Privacy | Mobile
Web04 | 2.6.130516.1 | Last Updated 11 Aug 2002
Article Copyright 2002 by rosen
Everything else Copyright © CodeProject, 1999-2013
Terms of Use
Layout: fixed | fluid