SlideShare ist ein Scribd-Unternehmen logo
1 von 9
Xml dom
By
Sana mateen
DOM
• The Document Object Model (DOM) is a W3C standard. It defines a
standard for accessing documents like HTML and XML.
• Definition of DOM as put by the W3C is:
• The Document Object Model (DOM) is an application programming
interface (API) for HTML and XML documents. It defines the logical
structure of documents and the way a document is accessed and
manipulated. DOM defines the objects and properties and methods
(interface) to access all XML elements. The DOM is separated into 3
different parts / levels:
• Core DOM - standard model for any structured document
• XML DOM - standard model for XML documents
• HTML DOM - standard model for HTML documents
XML DOM
• XML DOM is a standard object model for XML.
• XML documents have a hierarchy of informational units called nodes;
DOM is a standard programming interface of describing those nodes and
the relationships between them.
• As XML DOM also provides an API that allows a developer to add, edit,
move or remove nodes at any point on the tree in order to create an
application.
• Below is the diagram for the DOM structure which depicts that parser
evaluates an XML document as a DOM structure by traversing through
each nodes.
ADVANTAGES and DISADVANTAGES
• XML DOM is language and
platform independent.
• XML DOM is travesible -
Information in XML DOM is
organized in a hierarchy which
allows developer to navigate
around the hierarchy looking for
specific information.
• XML DOM is modifiable - It is
dynamic in nature providing
developer a scope to add, edit,
move or remove nodes at any
point on the tree.
• It consumes more memory (if the
XML structure is large) as
program written once remains in
memory all the time until and
unless removed explicitly.
• Due to the larger usage of
memory its operational speed,
compared to SAX is slower.
Dom Document
• A DOM document is a collection of nodes or pieces of information,
organized in a hierarchy.
• Some types of nodes may have child nodes of various types and others are
leaf nodes that cannot have anything below them in the document structure.
• Below is a list of the node types, and which node types they may have as
children:
• Document -- Element (maximum of one), ProcessingInstruction, Comment,
DocumentType (maximum of one)
• DocumentFragment -- Element, ProcessingInstruction, Comment, Text,
CDATASection, EntityReference
• EntityReference -- Element, ProcessingInstruction, Comment, Text,
CDATASection, EntityReference
• Element -- Element, Text, Comment, ProcessingInstruction,
CDATASection, EntityReference
• Attr -- Text, EntityReference
• ProcessingInstruction -- no children
• Comment -- no children
• Text -- no children
• CDATASection -- no children
• Entity -- Element, ProcessingInstruction, Comment, Text, CDATASection,
EntityReference
• Notation -- no children
Xml dom -- nodes
• Every XML DOM contains the information in hierarchical units
called Nodes and
• the DOM describes these nodes and the relationship between theNode
Types
• The following pictorial representations lists all the node types:

Weitere ähnliche Inhalte

Was ist angesagt?

Javascript variables and datatypes
Javascript variables and datatypesJavascript variables and datatypes
Javascript variables and datatypes
Varun C M
 
Introduction to Web Programming - first course
Introduction to Web Programming - first courseIntroduction to Web Programming - first course
Introduction to Web Programming - first course
Vlad Posea
 

Was ist angesagt? (20)

XML
XMLXML
XML
 
Php forms
Php formsPhp forms
Php forms
 
File in C language
File in C languageFile in C language
File in C language
 
Javascript variables and datatypes
Javascript variables and datatypesJavascript variables and datatypes
Javascript variables and datatypes
 
Xml
XmlXml
Xml
 
Introduction to Web Programming - first course
Introduction to Web Programming - first courseIntroduction to Web Programming - first course
Introduction to Web Programming - first course
 
Type casting in java
Type casting in javaType casting in java
Type casting in java
 
WSDL
WSDLWSDL
WSDL
 
An Introduction to the DOM
An Introduction to the DOMAn Introduction to the DOM
An Introduction to the DOM
 
Web html table tags
Web html  table tagsWeb html  table tags
Web html table tags
 
DOM and SAX
DOM and SAXDOM and SAX
DOM and SAX
 
Object Oriented Programming In .Net
Object Oriented Programming In .NetObject Oriented Programming In .Net
Object Oriented Programming In .Net
 
Servlet life cycle
Servlet life cycleServlet life cycle
Servlet life cycle
 
Xml processors
Xml processorsXml processors
Xml processors
 
Css lecture notes
Css lecture notesCss lecture notes
Css lecture notes
 
Xml schema
Xml schemaXml schema
Xml schema
 
Html ppt
Html pptHtml ppt
Html ppt
 
XML Introduction
XML IntroductionXML Introduction
XML Introduction
 
DTD
DTDDTD
DTD
 
Introduction to php
Introduction to phpIntroduction to php
Introduction to php
 

Andere mochten auch

Andere mochten auch (13)

Jdbc in servlets
Jdbc in servletsJdbc in servlets
Jdbc in servlets
 
Understanding layout managers
Understanding layout managersUnderstanding layout managers
Understanding layout managers
 
Using cookies and sessions
Using cookies and sessionsUsing cookies and sessions
Using cookies and sessions
 
Reading init param
Reading init paramReading init param
Reading init param
 
Jsp elements
Jsp elementsJsp elements
Jsp elements
 
Xhtml
XhtmlXhtml
Xhtml
 
Intro xml
Intro xmlIntro xml
Intro xml
 
Events1
Events1Events1
Events1
 
Quiz app(j tabbed pane,jdialog,container,actionevent,jradiobutton,buttongroup...
Quiz app(j tabbed pane,jdialog,container,actionevent,jradiobutton,buttongroup...Quiz app(j tabbed pane,jdialog,container,actionevent,jradiobutton,buttongroup...
Quiz app(j tabbed pane,jdialog,container,actionevent,jradiobutton,buttongroup...
 
Xml dtd
Xml dtdXml dtd
Xml dtd
 
Xml schema
Xml schemaXml schema
Xml schema
 
Http request and http response
Http request and http responseHttp request and http response
Http request and http response
 
Dom parser
Dom parserDom parser
Dom parser
 

Ähnlich wie Xml dom

Understanding Dom
Understanding DomUnderstanding Dom
Understanding Dom
LiquidHub
 

Ähnlich wie Xml dom (20)

DOM-XML
DOM-XMLDOM-XML
DOM-XML
 
Unit iv xml dom
Unit iv xml domUnit iv xml dom
Unit iv xml dom
 
HTML_DOM
HTML_DOMHTML_DOM
HTML_DOM
 
uptu web technology unit 2 Xml2
uptu web technology unit 2 Xml2uptu web technology unit 2 Xml2
uptu web technology unit 2 Xml2
 
XML-Extensible Markup Language
XML-Extensible Markup Language XML-Extensible Markup Language
XML-Extensible Markup Language
 
Xml
XmlXml
Xml
 
Xml3
Xml3Xml3
Xml3
 
Xml and xml processor
Xml and xml processorXml and xml processor
Xml and xml processor
 
Xml and xml processor
Xml and xml processorXml and xml processor
Xml and xml processor
 
XML - SAX
XML - SAXXML - SAX
XML - SAX
 
XMl
XMlXMl
XMl
 
Xml
XmlXml
Xml
 
Xml parsing
Xml parsingXml parsing
Xml parsing
 
Xml iet 2015
Xml iet 2015Xml iet 2015
Xml iet 2015
 
Understanding Dom
Understanding DomUnderstanding Dom
Understanding Dom
 
Xml3
Xml3Xml3
Xml3
 
Markup For Dummies (Russ Ward)
Markup For Dummies (Russ Ward)Markup For Dummies (Russ Ward)
Markup For Dummies (Russ Ward)
 
Web data management
Web data managementWeb data management
Web data management
 
Xml
XmlXml
Xml
 
Introduction to XML.ppt
Introduction to XML.pptIntroduction to XML.ppt
Introduction to XML.ppt
 

Mehr von sana mateen

Mehr von sana mateen (20)

Files
FilesFiles
Files
 
PHP Variables and scopes
PHP Variables and scopesPHP Variables and scopes
PHP Variables and scopes
 
Php intro
Php introPhp intro
Php intro
 
Php and web forms
Php and web formsPhp and web forms
Php and web forms
 
Mail
MailMail
Mail
 
Files in php
Files in phpFiles in php
Files in php
 
File upload php
File upload phpFile upload php
File upload php
 
Regex posix
Regex posixRegex posix
Regex posix
 
Encryption in php
Encryption in phpEncryption in php
Encryption in php
 
Authentication methods
Authentication methodsAuthentication methods
Authentication methods
 
Unit 1-subroutines in perl
Unit 1-subroutines in perlUnit 1-subroutines in perl
Unit 1-subroutines in perl
 
Unit 1-uses for scripting languages,web scripting
Unit 1-uses for scripting languages,web scriptingUnit 1-uses for scripting languages,web scripting
Unit 1-uses for scripting languages,web scripting
 
Unit 1-strings,patterns and regular expressions
Unit 1-strings,patterns and regular expressionsUnit 1-strings,patterns and regular expressions
Unit 1-strings,patterns and regular expressions
 
Unit 1-scalar expressions and control structures
Unit 1-scalar expressions and control structuresUnit 1-scalar expressions and control structures
Unit 1-scalar expressions and control structures
 
Unit 1-perl names values and variables
Unit 1-perl names values and variablesUnit 1-perl names values and variables
Unit 1-perl names values and variables
 
Unit 1-introduction to scripts
Unit 1-introduction to scriptsUnit 1-introduction to scripts
Unit 1-introduction to scripts
 
Unit 1-introduction to perl
Unit 1-introduction to perlUnit 1-introduction to perl
Unit 1-introduction to perl
 
Unit 1-array,lists and hashes
Unit 1-array,lists and hashesUnit 1-array,lists and hashes
Unit 1-array,lists and hashes
 
Uses for scripting languages,web scripting in perl
Uses for scripting languages,web scripting in perlUses for scripting languages,web scripting in perl
Uses for scripting languages,web scripting in perl
 
Scalar expressions and control structures in perl
Scalar expressions and control structures in perlScalar expressions and control structures in perl
Scalar expressions and control structures in perl
 

Kürzlich hochgeladen

Standard vs Custom Battery Packs - Decoding the Power Play
Standard vs Custom Battery Packs - Decoding the Power PlayStandard vs Custom Battery Packs - Decoding the Power Play
Standard vs Custom Battery Packs - Decoding the Power Play
Epec Engineered Technologies
 
Call Girls In Bangalore ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Bangalore ☎ 7737669865 🥵 Book Your One night StandCall Girls In Bangalore ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Bangalore ☎ 7737669865 🥵 Book Your One night Stand
amitlee9823
 
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak HamilCara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
Cara Menggugurkan Kandungan 087776558899
 
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
dharasingh5698
 
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
dharasingh5698
 
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort ServiceCall Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
ssuser89054b
 

Kürzlich hochgeladen (20)

Standard vs Custom Battery Packs - Decoding the Power Play
Standard vs Custom Battery Packs - Decoding the Power PlayStandard vs Custom Battery Packs - Decoding the Power Play
Standard vs Custom Battery Packs - Decoding the Power Play
 
DC MACHINE-Motoring and generation, Armature circuit equation
DC MACHINE-Motoring and generation, Armature circuit equationDC MACHINE-Motoring and generation, Armature circuit equation
DC MACHINE-Motoring and generation, Armature circuit equation
 
Call Girls In Bangalore ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Bangalore ☎ 7737669865 🥵 Book Your One night StandCall Girls In Bangalore ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Bangalore ☎ 7737669865 🥵 Book Your One night Stand
 
Generative AI or GenAI technology based PPT
Generative AI or GenAI technology based PPTGenerative AI or GenAI technology based PPT
Generative AI or GenAI technology based PPT
 
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak HamilCara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
 
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
 
Navigating Complexity: The Role of Trusted Partners and VIAS3D in Dassault Sy...
Navigating Complexity: The Role of Trusted Partners and VIAS3D in Dassault Sy...Navigating Complexity: The Role of Trusted Partners and VIAS3D in Dassault Sy...
Navigating Complexity: The Role of Trusted Partners and VIAS3D in Dassault Sy...
 
Introduction to Serverless with AWS Lambda
Introduction to Serverless with AWS LambdaIntroduction to Serverless with AWS Lambda
Introduction to Serverless with AWS Lambda
 
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
 
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
 
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort ServiceCall Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
 
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
 
Unit 2- Effective stress & Permeability.pdf
Unit 2- Effective stress & Permeability.pdfUnit 2- Effective stress & Permeability.pdf
Unit 2- Effective stress & Permeability.pdf
 
chapter 5.pptx: drainage and irrigation engineering
chapter 5.pptx: drainage and irrigation engineeringchapter 5.pptx: drainage and irrigation engineering
chapter 5.pptx: drainage and irrigation engineering
 
UNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its PerformanceUNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its Performance
 
2016EF22_0 solar project report rooftop projects
2016EF22_0 solar project report rooftop projects2016EF22_0 solar project report rooftop projects
2016EF22_0 solar project report rooftop projects
 
Unit 1 - Soil Classification and Compaction.pdf
Unit 1 - Soil Classification and Compaction.pdfUnit 1 - Soil Classification and Compaction.pdf
Unit 1 - Soil Classification and Compaction.pdf
 
data_management_and _data_science_cheat_sheet.pdf
data_management_and _data_science_cheat_sheet.pdfdata_management_and _data_science_cheat_sheet.pdf
data_management_and _data_science_cheat_sheet.pdf
 
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
 
Bhosari ( Call Girls ) Pune 6297143586 Hot Model With Sexy Bhabi Ready For ...
Bhosari ( Call Girls ) Pune  6297143586  Hot Model With Sexy Bhabi Ready For ...Bhosari ( Call Girls ) Pune  6297143586  Hot Model With Sexy Bhabi Ready For ...
Bhosari ( Call Girls ) Pune 6297143586 Hot Model With Sexy Bhabi Ready For ...
 

Xml dom

  • 2. DOM • The Document Object Model (DOM) is a W3C standard. It defines a standard for accessing documents like HTML and XML. • Definition of DOM as put by the W3C is: • The Document Object Model (DOM) is an application programming interface (API) for HTML and XML documents. It defines the logical structure of documents and the way a document is accessed and manipulated. DOM defines the objects and properties and methods (interface) to access all XML elements. The DOM is separated into 3 different parts / levels: • Core DOM - standard model for any structured document • XML DOM - standard model for XML documents • HTML DOM - standard model for HTML documents
  • 3. XML DOM • XML DOM is a standard object model for XML. • XML documents have a hierarchy of informational units called nodes; DOM is a standard programming interface of describing those nodes and the relationships between them. • As XML DOM also provides an API that allows a developer to add, edit, move or remove nodes at any point on the tree in order to create an application. • Below is the diagram for the DOM structure which depicts that parser evaluates an XML document as a DOM structure by traversing through each nodes.
  • 4.
  • 5. ADVANTAGES and DISADVANTAGES • XML DOM is language and platform independent. • XML DOM is travesible - Information in XML DOM is organized in a hierarchy which allows developer to navigate around the hierarchy looking for specific information. • XML DOM is modifiable - It is dynamic in nature providing developer a scope to add, edit, move or remove nodes at any point on the tree. • It consumes more memory (if the XML structure is large) as program written once remains in memory all the time until and unless removed explicitly. • Due to the larger usage of memory its operational speed, compared to SAX is slower.
  • 6. Dom Document • A DOM document is a collection of nodes or pieces of information, organized in a hierarchy. • Some types of nodes may have child nodes of various types and others are leaf nodes that cannot have anything below them in the document structure. • Below is a list of the node types, and which node types they may have as children: • Document -- Element (maximum of one), ProcessingInstruction, Comment, DocumentType (maximum of one) • DocumentFragment -- Element, ProcessingInstruction, Comment, Text, CDATASection, EntityReference • EntityReference -- Element, ProcessingInstruction, Comment, Text, CDATASection, EntityReference • Element -- Element, Text, Comment, ProcessingInstruction, CDATASection, EntityReference
  • 7. • Attr -- Text, EntityReference • ProcessingInstruction -- no children • Comment -- no children • Text -- no children • CDATASection -- no children • Entity -- Element, ProcessingInstruction, Comment, Text, CDATASection, EntityReference • Notation -- no children
  • 8.
  • 9. Xml dom -- nodes • Every XML DOM contains the information in hierarchical units called Nodes and • the DOM describes these nodes and the relationship between theNode Types • The following pictorial representations lists all the node types: