12xml-2up - 12 XML 23 Sept, 2010 "XML has replaced...

Info iconThis preview shows pages 1–4. Sign up to view the full content.

View Full Document Right Arrow Icon
12 XML 23 Sept, 2010 CSCC09 Programming on the Web 1 12 -XML CSCC09 1 XML design goals, usage, syntax, Processing Instructions, Stylesheets DTD’s – elements, attributes, &entities; CDATA, namespaces "XML has replaced Java, Design Patterns and Object Technology as the software industry's solution to world hunger" - Don Box,et al., "Essential XML", Addison Wesley, 2000. 12 -XML CSCC09 2 XML b Definitive specification at b http://www.w3.org/TR/REC-xml b http://www.xml.com/axml/axml.html (annotated) b eXtensible Markup Language b a lightweight subset of SGML b enables [a subset of] generic SGML to be served, received and processed on the Web as is now possible for HTML b designed for: b ease of implementation b interoperability with SGML and HTML
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
12 XML 23 Sept, 2010 CSCC09 Programming on the Web 2 12 -XML CSCC09 3 HTML and XML b HTML is an SGML application or vocabulary, that is, it defines a specific markup language (tag set) and specifies its meaning (how a browser should interpret the markup) to display the document b XML is not an SGML application, it is an SGML subset , a subtle but important difference b XML is e X tensible, it allows you to define your own markup (tags) and to describe nested hierarchies of information, e.g.: b MathML, voiceXML, MusicML, SVG, app config files b Since XML is extensible, an XML document should be accompanied by its DTD, describing its syntax 12 -XML CSCC09 4 Hello World in XML b An XML document with external DTD: <?xml version="1.0"?> <!DOCTYPE greeting SYSTEM "hello.dtd"> <greeting>Hello World!</greeting> b An XML document with embedded DTD: <?xml version="1.0"? standalone =“yes” ?> <!DOCTYPE greeting [ <!ELEMENT greeting (#PCDATA)> ]> <greeting>Hello World!</greeting> b This simple example illustrates an issue some have raised about XML as a data representation language
Background image of page 2
23 Sept, 2010 CSCC09 Programming on the Web 3 12 -XML CSCC09 7 XML Usage b Defining, storing and transmitting structured data b for traditional data processing, XML documents can serve as the data interchange medium, esp for network-based apps b for coupling between different application file formats b to define the content of messages, e.g. the Web Services SOAP protocol is expressed in XML b A framework for standardizing semantic data b e.g. the “semantic” web, business agreements and terms of service between companies b A new basis for defining HTML (XHTML) b supports modular definition of HTML for different uses, e.g. desktop vs mobile 12 -XML CSCC09 8 XML Usage b Document-driven programming – references to plug- in components, such as Java Beans, allow specification of active as well as passive document components, e.g. in Java Server Pages (JSP) docs b Object archiving – text more convenient than binary for object serialization, for modification of stored objects and exchange of objects between different languages b Describing arbitrary XML to XML translation b translating data amongst interfaces b translating data into XHTML for display
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 4
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 21

12xml-2up - 12 XML 23 Sept, 2010 &quot;XML has replaced...

This preview shows document pages 1 - 4. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online