Exercise 11

XML Introduction

1. Conduct research on the Internet to find out what tools can be used to parse an XML document and ensure that the document is well formed and valid.

XML Parsers:

XML Parser Programming Language
4Suite Server (4SS) Python
Ælfred Java
Electric XML Java
ESPX ECMAScript
Expat C
eXML Eiffel
ezXML C
FastXML C++
fxp: functional XML parser Standard ML
HEX Java
HXML Haskell
IBM’s XML for Java EA2 Java
Lark Java
MSXML Microsoft .NET
libxml C
Minimum Size XML Parser (MXP1) Java
NanoXML Java
Oracle’s XML Parser for Java v2 Java
POCO – The C++ Portable Components C++
REXML Ruby
RXP C
Serving XML Java
Polymorphic XML Parser (PXP) Objective Caml
Xerces C++ C++
Xerces-J Java
XML Engine REALbasic
XML Parser for Allegro CL LISP
XML Validator C++
XML::Twig Perl
XMLBooster C, C++, COBOL, Delphi and Java
XMLtp 1.3 Java

2. XML schema is a forthcoming development of the technology. Visit the W3C website and search for information on the schema. What are the benefits of adopting a schema standardized for a business sector?

The benefits of adopting a schema standardized for the business sector is so that applications are able to uniformly apply validation rules to Document Data Types (DDT) so that there is no ambiguity between data type information. This would “ensure robustness in document understanding and data interchange” [3], so that information could be exchanged without the need for “applications writers… to implement type checking in an ad hoc manner”. [3]

What are DOMs and why are they developed?

DOM stands for Document Object Model it “defines a standard way for accessing and manipulating XML documents” [4] and it uses a “cross-platform and language-independent convention” [5].

They were developed so that applications could interact with the objects in XML documents using the “DOM Application Programming Interface (API)” [5].

4. Why are some developers using SAX instead of DOM for document processing?

SAX stands for “serial access parser API for XML” [6] and is used to “read data from an XML document”. [6]

Developers are using SAX over DOM for document processing, for the following reasons:

  • The SAX parser has a smaller memory footprint, [6]
  • SAX processing is faster than DOM-style parsers, due to the event driven nature of SAX, and [6]
  • SAX parsers can process XML documents larger than main memory wheras DOM parsers can’t. [6]

5. SMIL is an application of XML. What is the purpose of this technology? Where does it apply?

SMIL stands for Synchronized Multimedia Integration Language and it “enables simple authoring of interactive audiovisual presentations”. [7]

The purpose of this technology is “for describing multimedia presentations”. [8]

Currently SMIL has been applied to the following industries/applications:

  • Handheld and mobile devices,
  • HD DVD,
  • Digital Signage

6. The current recommendation of W3C is to use XHTML as an alternative to HTML.

7. Do you think adopting XHTML is a wise move?

Whilst it might seem like a wise move because the W3C recommends adopting XHTML as an alternative to HTML, I think you have to look at the current adoption of XHTML standards by the major browsers to determine if it is a good idea.

The problem at the moment is that “not all browsers recognise application/xhtml+xml” MIME type [9]. Currently Internet Explorer does not recognise the MIME type ‘application/xhtml+xml’[10]. So I don’t think it’s a wise move until all major browsers recognise the MIME type ‘application/xhtml+xml’.


References

Question 1

O’Reilly XML.com, XML Parsers (n.d.). Retrieved 17th June 2009 from http://www.xml.com/pub/rg/XML_Parsers

Web Developers virtual library, XML Software Guide: XML Parsers (n.d.). Retrieved 17th June 2009 from http://wdvl.internet.com/Software/XML/parsers.html

Question 2

W3C, W3C XML Schema Definition Language (XSD) 1.1 Part 2: Datatypes. W3C Candidate Recommendation 30 April 2009. (30 April 2009.). Retrieved 17th June 2009 from http://www.w3.org/TR/xmlschema11-2/#purpose

W3C, W3C XML Schema Definition Language (XSD) 1.1 Part 1: Structures. W3C Candidate Recommendation 30 April 2009 (30 April 2009.). Retrieved 17th June 2009 from http://www.w3.org/TR/xmlschema11-1/

Question 3

w3schools.com. XML DOM Tutorial(n.d.). Retrieved 17th June 2009 from http://www.w3schools.com/dom/default.asp

Wikipedia. Document Object Model. (n.d.). Retrieved 17th June 2009 from http://en.wikipedia.org/wiki/Document_Object_Model

Question 4

Wikipedia. Simple API for XML. (n.d.). Retrieved 17th June 2009 from http://en.wikipedia.org/wiki/Simple_API_for_XML

Question 5

W3C. Synchronized Multimedia. (n.d.). Retrieved 17th June 2009 from http://www.w3.org/AudioVideo/

Wikipedia. Synchronized Multimedia Integration Language. (n.d.). Retrieved 17th June 2009 from http://en.wikipedia.org/wiki/Synchronized_Multimedia_Integration_Language

Question 7

schillmania. Application/xhtml+xml. (n.d.). Retrieved 17th June 2009 from http://www.schillmania.com/content/entries/2004/10/24/application-xhtml+xml/

W3C. HTML and XHTML Frequently Answered Questions. (21 July 2004). Retrieved 17th June 2009 from http://www.w3.org/MarkUp/2004/xhtml-faq#browsers

Leave a Reply