SlideShare una empresa de Scribd logo
1 de 20
Disclaimer: This presentation is prepared by trainees of
baabtra as a part of mentoring program. This is not official
document of baabtra –Mentoring Partner
Baabtra-Mentoring Partner is the mentoring division of baabte System Technologies Pvt .
Ltd
eXtensible Markup
    Language
BASIC POINTS ABOUT XML
• XML allows data to be stored in either
  elements or attributes.
• Elements and attributes can be named to give
  the data meaning.
• Start tags and end tags define elements that
  are the basis for XML tree-structured
  representations of documents.
• Elements can contain text data and/or other
  elements.
XML ADVANTAGES
• XML files are human-readable . Such is not the
  case with binary data formats
• Widespread industry support exists for XML.
  Numerous tools and utilities are being
  provided with Web browsers, databases, and
  operating systems, making it easier and less
  expensive for small and medium-sized
  organizations to import and export data in
  XML format.
• Major relational databases now have the
  native capability to read and generate XML
  data.
• A large family of XML support technologiesis
  availablefor the interpretation and
  transformation of XML data for Web page
  display and report generation.
COMPARISON
             XML                      HTML
• Extensible set of tags   • Fixed set of tags
• Content orientated       • Presentation oriented
• Standard Data            • No data validation
  infrastructure             capabilities
• Allows multiple          • Single presentation
• output forms
XML-RELATED TECHNOLOGIES
• DTD(Document Type Definition) and XML
  Schemas are used to define legal XML tags
  and their attributes for particular purposes
• CSS(Cascading Style Sheets) describe how to
  display HTML or XML in a browser.
• XSLT (eXtensible Stylesheet Language
  Traformations) and Xpath are used to
  translate from of xml to another
OVERALL STRUCTURE
• An XML document may start with one or more
  processing instructions(PI) or directives:
• <?xml version =“1.0”?>
• <?xml-stylesheet type=“text/css” href=“ss.css”
• Following the directives,there must be excatly one
  tag, called the root element,containing all the rest of
  the XML:
• <weatherReport>
   ………
</weatheReport>
XML SCHEAMS
• “Schemas” is a general term--DTDs are a form
  of XML schemas
• When we say “XML Schemas,” we usually
  mean the W3C XML Schema Language
• DTDs, XML Schemas, and RELAX NG are all
  XML schema languages
Why XML Schemas?
• DTDs provide a very weak specification
  language
• DTDs are written in a strange (non-XML)
  format
• The XML Schema Definition language solves
  these problems
XML PARSER
• It is a software library (or a package) that
  provides methods (or interfaces) for client
  applications to work with XML documents
• It checks the well-formattedness
• It may validate the documents
• It does a lot of other detailed things so that a
  client is shielded from that complexities
Parse an XML Document
•   The following code fragment parses an XML document into an XML DOM
    object
     if (window.XMLHttpRequest)
     {// code for IE7+, Firefox, Chrome, Opera, Safari
     xmlhttp=new XMLHttpRequest();
     }
    else
     {// code for IE6, IE5
     xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
     }
    xmlhttp.open("GET","books.xml",false);
    xmlhttp.send();
    xmlDoc=xmlhttp.responseXML
Parse an XML String
• The following code fragment parses an XML string
  into an XML DOM object:
•   txt="<bookstore><book>";
    txt=txt+"<title>Everyday Italian</title>";
    txt=txt+"<author>Giada De Laurentiis</author>";
    txt=txt+"<year>2005</year>";
    txt=txt+"</book></bookstore>";

    if (window.DOMParser)
      {
      parser=new DOMParser();
      xmlDoc=parser.parseFromString(txt,"text/xml");
      }
    else // Internet Explorer
      {
      xmlDoc=new ActiveXObject("Microsoft.XMLDOM");
      xmlDoc.async=false;
      xmlDoc.loadXML(txt);

      }
GladeXML
Object Hierarchy
This object represents an `instantiation' of an XML interface description.
   When one of these objects is created, the XML file is read, and the
   interface is created. The GladeXML object then provides an interface for
   accessing the widgets in the interface by the names assigned to them
   inside the XML description.

GObject +----
 GladeXML
GladeXML
typedef struct {
   GObject parent;
   char *filename; }
GladeXML;
GladeXMLClass
typedef struct
  {
     GObjectClass parent_class;
    /* Virtual function: gets the appropriate gtype for
    the typename.*/
    GType (* lookup_type) (GladeXML*self, const char
    *gtypename);
  } GladeXMLClass;
If this presentation helped you, please visit our page
               facebook.com/baabtra and like it.
                  Thanks in advance.
www.baabtra.com | www.massbaab.com |www.baabte.com
Contact Us

Más contenido relacionado

La actualidad más candente

XML Document Object Model (DOM)
XML Document Object Model (DOM)XML Document Object Model (DOM)
XML Document Object Model (DOM)BOSS Webtech
 
Introduction to XML
Introduction to XMLIntroduction to XML
Introduction to XMLKumar
 
Introduction to XML and Databases
Introduction to XML and DatabasesIntroduction to XML and Databases
Introduction to XML and Databasestorp42
 
Xml data transformation
Xml data transformationXml data transformation
Xml data transformationRaghu nath
 
HTML and XML Difference FAQs
HTML and XML Difference FAQsHTML and XML Difference FAQs
HTML and XML Difference FAQsUmar Ali
 
01 xml document structure
01 xml document structure01 xml document structure
01 xml document structureBaskarkncet
 
XML and Databases
XML and DatabasesXML and Databases
XML and DatabasesCittrex
 
Introduction to XML
Introduction to XMLIntroduction to XML
Introduction to XMLPrabu U
 
Document Object Model (DOM)
Document Object Model (DOM)Document Object Model (DOM)
Document Object Model (DOM)GOPAL BASAK
 
Xml theory 2005_[ngohaianh.info]_1_introduction-to-xml
Xml theory 2005_[ngohaianh.info]_1_introduction-to-xmlXml theory 2005_[ngohaianh.info]_1_introduction-to-xml
Xml theory 2005_[ngohaianh.info]_1_introduction-to-xmlÔng Thông
 

La actualidad más candente (20)

Introduction to XML
Introduction to XMLIntroduction to XML
Introduction to XML
 
XML Document Object Model (DOM)
XML Document Object Model (DOM)XML Document Object Model (DOM)
XML Document Object Model (DOM)
 
Introduction to XML
Introduction to XMLIntroduction to XML
Introduction to XML
 
Introduction to XML and Databases
Introduction to XML and DatabasesIntroduction to XML and Databases
Introduction to XML and Databases
 
Intro xml
Intro xmlIntro xml
Intro xml
 
Xml data transformation
Xml data transformationXml data transformation
Xml data transformation
 
Processing XML
Processing XMLProcessing XML
Processing XML
 
HTML and XML Difference FAQs
HTML and XML Difference FAQsHTML and XML Difference FAQs
HTML and XML Difference FAQs
 
01 xml document structure
01 xml document structure01 xml document structure
01 xml document structure
 
Xml databases
Xml databasesXml databases
Xml databases
 
XML and Databases
XML and DatabasesXML and Databases
XML and Databases
 
Introduction to XML
Introduction to XMLIntroduction to XML
Introduction to XML
 
Xml presentation
Xml presentationXml presentation
Xml presentation
 
uptu web technology unit 2 Xml2
uptu web technology unit 2 Xml2uptu web technology unit 2 Xml2
uptu web technology unit 2 Xml2
 
Introduction to XML
Introduction to XMLIntroduction to XML
Introduction to XML
 
Xml3
Xml3Xml3
Xml3
 
XML
XMLXML
XML
 
Document Object Model (DOM)
Document Object Model (DOM)Document Object Model (DOM)
Document Object Model (DOM)
 
Xml theory 2005_[ngohaianh.info]_1_introduction-to-xml
Xml theory 2005_[ngohaianh.info]_1_introduction-to-xmlXml theory 2005_[ngohaianh.info]_1_introduction-to-xml
Xml theory 2005_[ngohaianh.info]_1_introduction-to-xml
 
DOM-XML
DOM-XMLDOM-XML
DOM-XML
 

Destacado (7)

DOM Structure
DOM StructureDOM Structure
DOM Structure
 
Leadership Qualities
Leadership QualitiesLeadership Qualities
Leadership Qualities
 
Encapsulation
EncapsulationEncapsulation
Encapsulation
 
Cascade.ss
Cascade.ssCascade.ss
Cascade.ss
 
How to setup android development environment baabtra Android Workshop Kit?
How to setup android development environment baabtra Android Workshop Kit?How to setup android development environment baabtra Android Workshop Kit?
How to setup android development environment baabtra Android Workshop Kit?
 
Responsive design
Responsive designResponsive design
Responsive design
 
Industrial training project management session2
Industrial training project management session2Industrial training project management session2
Industrial training project management session2
 

Similar a Xml (20)

XML
XMLXML
XML
 
Xml
XmlXml
Xml
 
1 xml fundamentals
1 xml fundamentals1 xml fundamentals
1 xml fundamentals
 
Xml
XmlXml
Xml
 
Xml
XmlXml
Xml
 
CTDA Workshop on XML and MODS
CTDA Workshop on XML and MODSCTDA Workshop on XML and MODS
CTDA Workshop on XML and MODS
 
Markup For Dummies (Russ Ward)
Markup For Dummies (Russ Ward)Markup For Dummies (Russ Ward)
Markup For Dummies (Russ Ward)
 
advDBMS_XML.pptx
advDBMS_XML.pptxadvDBMS_XML.pptx
advDBMS_XML.pptx
 
Data interchange integration, HTML XML Biological XML DTD
Data interchange integration, HTML XML Biological XML DTDData interchange integration, HTML XML Biological XML DTD
Data interchange integration, HTML XML Biological XML DTD
 
Unit3wt
Unit3wtUnit3wt
Unit3wt
 
Unit3wt
Unit3wtUnit3wt
Unit3wt
 
Ch2 neworder
Ch2 neworderCh2 neworder
Ch2 neworder
 
Xml and DTD's
Xml and DTD'sXml and DTD's
Xml and DTD's
 
XML notes.pptx
XML notes.pptxXML notes.pptx
XML notes.pptx
 
Xml iet 2015
Xml iet 2015Xml iet 2015
Xml iet 2015
 
Xml
XmlXml
Xml
 
Unit iv xml dom
Unit iv xml domUnit iv xml dom
Unit iv xml dom
 
Xhtml
XhtmlXhtml
Xhtml
 
DATA INTEGRATION (Gaining Access to Diverse Data).ppt
DATA INTEGRATION (Gaining Access to Diverse Data).pptDATA INTEGRATION (Gaining Access to Diverse Data).ppt
DATA INTEGRATION (Gaining Access to Diverse Data).ppt
 
XML
XMLXML
XML
 

Más de baabtra.com - No. 1 supplier of quality freshers

Más de baabtra.com - No. 1 supplier of quality freshers (20)

Agile methodology and scrum development
Agile methodology and scrum developmentAgile methodology and scrum development
Agile methodology and scrum development
 
Best coding practices
Best coding practicesBest coding practices
Best coding practices
 
Core java - baabtra
Core java - baabtraCore java - baabtra
Core java - baabtra
 
Acquiring new skills what you should know
Acquiring new skills   what you should knowAcquiring new skills   what you should know
Acquiring new skills what you should know
 
Baabtra.com programming at school
Baabtra.com programming at schoolBaabtra.com programming at school
Baabtra.com programming at school
 
99LMS for Enterprises - LMS that you will love
99LMS for Enterprises - LMS that you will love 99LMS for Enterprises - LMS that you will love
99LMS for Enterprises - LMS that you will love
 
Php sessions & cookies
Php sessions & cookiesPhp sessions & cookies
Php sessions & cookies
 
Php database connectivity
Php database connectivityPhp database connectivity
Php database connectivity
 
Chapter 6 database normalisation
Chapter 6  database normalisationChapter 6  database normalisation
Chapter 6 database normalisation
 
Chapter 5 transactions and dcl statements
Chapter 5  transactions and dcl statementsChapter 5  transactions and dcl statements
Chapter 5 transactions and dcl statements
 
Chapter 4 functions, views, indexing
Chapter 4  functions, views, indexingChapter 4  functions, views, indexing
Chapter 4 functions, views, indexing
 
Chapter 3 stored procedures
Chapter 3 stored proceduresChapter 3 stored procedures
Chapter 3 stored procedures
 
Chapter 2 grouping,scalar and aggergate functions,joins inner join,outer join
Chapter 2  grouping,scalar and aggergate functions,joins   inner join,outer joinChapter 2  grouping,scalar and aggergate functions,joins   inner join,outer join
Chapter 2 grouping,scalar and aggergate functions,joins inner join,outer join
 
Chapter 1 introduction to sql server
Chapter 1 introduction to sql serverChapter 1 introduction to sql server
Chapter 1 introduction to sql server
 
Chapter 1 introduction to sql server
Chapter 1 introduction to sql serverChapter 1 introduction to sql server
Chapter 1 introduction to sql server
 
Microsoft holo lens
Microsoft holo lensMicrosoft holo lens
Microsoft holo lens
 
Blue brain
Blue brainBlue brain
Blue brain
 
5g
5g5g
5g
 
Aptitude skills baabtra
Aptitude skills baabtraAptitude skills baabtra
Aptitude skills baabtra
 
Gd baabtra
Gd baabtraGd baabtra
Gd baabtra
 

Xml

  • 1.
  • 2. Disclaimer: This presentation is prepared by trainees of baabtra as a part of mentoring program. This is not official document of baabtra –Mentoring Partner Baabtra-Mentoring Partner is the mentoring division of baabte System Technologies Pvt . Ltd
  • 3. eXtensible Markup Language
  • 4. BASIC POINTS ABOUT XML • XML allows data to be stored in either elements or attributes. • Elements and attributes can be named to give the data meaning. • Start tags and end tags define elements that are the basis for XML tree-structured representations of documents. • Elements can contain text data and/or other elements.
  • 5. XML ADVANTAGES • XML files are human-readable . Such is not the case with binary data formats • Widespread industry support exists for XML. Numerous tools and utilities are being provided with Web browsers, databases, and operating systems, making it easier and less expensive for small and medium-sized organizations to import and export data in XML format.
  • 6. • Major relational databases now have the native capability to read and generate XML data. • A large family of XML support technologiesis availablefor the interpretation and transformation of XML data for Web page display and report generation.
  • 7. COMPARISON XML HTML • Extensible set of tags • Fixed set of tags • Content orientated • Presentation oriented • Standard Data • No data validation infrastructure capabilities • Allows multiple • Single presentation • output forms
  • 8. XML-RELATED TECHNOLOGIES • DTD(Document Type Definition) and XML Schemas are used to define legal XML tags and their attributes for particular purposes • CSS(Cascading Style Sheets) describe how to display HTML or XML in a browser. • XSLT (eXtensible Stylesheet Language Traformations) and Xpath are used to translate from of xml to another
  • 9. OVERALL STRUCTURE • An XML document may start with one or more processing instructions(PI) or directives: • <?xml version =“1.0”?> • <?xml-stylesheet type=“text/css” href=“ss.css” • Following the directives,there must be excatly one tag, called the root element,containing all the rest of the XML: • <weatherReport> ……… </weatheReport>
  • 10. XML SCHEAMS • “Schemas” is a general term--DTDs are a form of XML schemas • When we say “XML Schemas,” we usually mean the W3C XML Schema Language • DTDs, XML Schemas, and RELAX NG are all XML schema languages
  • 11. Why XML Schemas? • DTDs provide a very weak specification language • DTDs are written in a strange (non-XML) format • The XML Schema Definition language solves these problems
  • 12. XML PARSER • It is a software library (or a package) that provides methods (or interfaces) for client applications to work with XML documents • It checks the well-formattedness • It may validate the documents • It does a lot of other detailed things so that a client is shielded from that complexities
  • 13.
  • 14. Parse an XML Document • The following code fragment parses an XML document into an XML DOM object if (window.XMLHttpRequest) {// code for IE7+, Firefox, Chrome, Opera, Safari xmlhttp=new XMLHttpRequest(); } else {// code for IE6, IE5 xmlhttp=new ActiveXObject("Microsoft.XMLHTTP"); } xmlhttp.open("GET","books.xml",false); xmlhttp.send(); xmlDoc=xmlhttp.responseXML
  • 15. Parse an XML String • The following code fragment parses an XML string into an XML DOM object: • txt="<bookstore><book>"; txt=txt+"<title>Everyday Italian</title>"; txt=txt+"<author>Giada De Laurentiis</author>"; txt=txt+"<year>2005</year>"; txt=txt+"</book></bookstore>"; if (window.DOMParser) { parser=new DOMParser(); xmlDoc=parser.parseFromString(txt,"text/xml"); } else // Internet Explorer { xmlDoc=new ActiveXObject("Microsoft.XMLDOM"); xmlDoc.async=false; xmlDoc.loadXML(txt); }
  • 16. GladeXML Object Hierarchy This object represents an `instantiation' of an XML interface description. When one of these objects is created, the XML file is read, and the interface is created. The GladeXML object then provides an interface for accessing the widgets in the interface by the names assigned to them inside the XML description. GObject +---- GladeXML
  • 17. GladeXML typedef struct { GObject parent; char *filename; } GladeXML;
  • 18. GladeXMLClass typedef struct { GObjectClass parent_class; /* Virtual function: gets the appropriate gtype for the typename.*/ GType (* lookup_type) (GladeXML*self, const char *gtypename); } GladeXMLClass;
  • 19. If this presentation helped you, please visit our page facebook.com/baabtra and like it. Thanks in advance. www.baabtra.com | www.massbaab.com |www.baabte.com