Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Why DOM Parser would take more Memory than SAX parser
while they are parsing?

Answer Posted / sandya

Both SAX and DOM are used to parse the XML document. Both
has advantages and disadvantages and can be used in our
programming depending on the situation

SAX:

1. Parses node by node

2. Doesnt store the XML in memory

3. We cant insert or delete a node

4. Top to bottom traversing

DOM

1. Stores the entire XML document into memory before processing

2. Occupies more memory

3. We can insert or delete nodes

4. Traverse in any direction.

If we need to find a node and doesnt need to insert or
delete we can go with SAX itself otherwise DOM provided we
have more memory.

Is This Answer Correct ?    11 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is threadfactory?

1042


A user of a web application sees a jsessionid argument in the URL whenever a resource is accessed. What does this mean? a. The form must have the field jsessionid b. URL rewriting is used as the session method c. Cookies are used for managing sessions

2197


Is there a guarantee of uniqueness for entity beans?

968


What are the different algorithms used for clustering?

1028


Why do I get a duplicate name error when loading a jar file?

1091


What is the difference between the string and stringbuffer classes?

1046


What is Remote Server?

2158


What is the RMI and Socket?

1017


what is a non-repeatable read?

2338


What is the diffrence between a local-tx-datasource and a xa-datasource?

1005


what are getters and setters in Java with examples?

1740


What is the infobus?

1043


What are various types of class loaders used by jvm?

939


What is permgen or permanent generation?

973


Difference between hashmap and hashtable?

1101