Presentation is loading. Please wait.

Presentation is loading. Please wait.

Updated 2003.11.14 10:02 Hong Kong University of Science & Technology Library Workshop on XML-Based Library Applications 1. What is XML?

Similar presentations


Presentation on theme: "Updated 2003.11.14 10:02 Hong Kong University of Science & Technology Library Workshop on XML-Based Library Applications 1. What is XML?"— Presentation transcript:

1 updated 2003.11.14 10:02 Hong Kong University of Science & Technology Library Workshop on XML-Based Library Applications 1. What is XML?

2 Hong Kong University of Science & Technology Library What is XML? (1) XML is eXtensible Markup Language XML is eXtensible Markup Language Like HTML, it contains tags " " for describing elements. Unlike HTML, XML by itself does not define any specific tags, but only describes how to define your own tags to use to mark up documents Like HTML, it contains tags " " for describing elements. Unlike HTML, XML by itself does not define any specific tags, but only describes how to define your own tags to use to mark up documents Developed by the W3C (World Wide Web Consortium) Developed by the W3C (World Wide Web Consortium) To learn more: W3C’s XML site http://www.w3.org/xml and the XMLFAQ @ http://www.uce.ie/xmlfaq To learn more: W3C’s XML site http://www.w3.org/xml and the XMLFAQ @ http://www.uce.ie/xmlfaq http://www.w3.org/xml http://www.uce.ie/xmlfaq http://www.w3.org/xml http://www.uce.ie/xmlfaq

3 Hong Kong University of Science & Technology Library What is XML? (2) How is it used? How is it used? Marking up data Marking up data Exchanging data between systems/applications Exchanging data between systems/applications Separating content from presentation Separating content from presentation A Meta-Language standard A Meta-Language standard (language that defines languages) Some languages: Some languages: PICS, EAD, Dublin Core, MARC

4 Hong Kong University of Science & Technology Library What is XML? (3) Example 1 - a bookstore?: Example 1 - a bookstore?: The Zen of Gardening The Zen of Gardening Randy Mullis Randy Mullis 39.99 39.99 Kitchen Decoration Kitchen Decoration Fleeta Wilkinson Fleeta Wilkinson 92.00 92.00

5 Hong Kong University of Science & Technology Library What is XML? (4) Example 2 - personal inventory?: Example 2 - personal inventory?: The Zen of Gardening The Zen of Gardening Randy Mullis Randy Mullis 39.99 39.99 Kitchen Decoration Kitchen Decoration Fleeta Wilkinson Fleeta Wilkinson 92.00 92.00 </homeinventory>

6 Hong Kong University of Science & Technology Library What is XML? (5) Relationship with SGML Relationship with SGML A subset to make SGML usable on the Web A subset to make SGML usable on the Web Relationship with HTML/XHTML Relationship with HTML/XHTML Extensible, form/content separation possible Extensible, form/content separation possible XHTML is an XML form of HTML XHTML is an XML form of HTML

7 Hong Kong University of Science & Technology Library Why Use XML? Widely accepted and adopted standard Widely accepted and adopted standard Independent of vendor, platform & applications Independent of vendor, platform & applications Many essential and emerging standards are based on XML Many essential and emerging standards are based on XML Multi-Script capable (UTF-8 compliant) Multi-Script capable (UTF-8 compliant) Web capable Web capable Plain-text source files Plain-text source files Has become the basic infrastructure in digital libraries and the information profession Has become the basic infrastructure in digital libraries and the information profession

8 Hong Kong University of Science & Technology Library Anatomy of XML (1) Elements and Attributes Elements and Attributes All elements are case sensitive All elements are case sensitive vs. vs. vs. vs. All elements must open and close All elements must open and close 39.99 39.99 All attribute values must be quoted All attribute values must be quoted 39.99 39.99

9 Hong Kong University of Science & Technology Library Anatomy of XML (2) Nesting Nesting<book> Kitchen Decoration Kitchen Decoration Fleeta Wilkinson Fleeta Wilkinson 92.00 92.00

10 Hong Kong University of Science & Technology Library Anatomy of XML (3) Hierarchical Hierarchical <bookcoll> The Zen of Gardening The Zen of Gardening Randy Mullis Randy Mullis 39.99 39.99 Kitchen Decoration Kitchen Decoration Fleeta Wilkinson Fleeta Wilkinson 12.95 12.95

11 Hong Kong University of Science & Technology Library Anatomy of XML (4) Namespaces Namespaces A collection of names, identified by a URI reference, which are used in XML documents as element types and attribute names. A collection of names, identified by a URI reference, which are used in XML documents as element types and attribute names. xmlns:dc=http://purl.org/dc/elements/1.1/ http://purl.org/dc/elements/1.1/ DOM - Document Object Model DOM - Document Object Model Exposes the contents of an XML document. The W3C's DOM defines what any DOM (e.g. Microsoft's) should expose as properties, methods, and events. Exposes the contents of an XML document. The W3C's DOM defines what any DOM (e.g. Microsoft's) should expose as properties, methods, and events. Example: Internet Explorer’s ability to display XML Example: Internet Explorer’s ability to display XMLXML

12 Hong Kong University of Science & Technology Library Anatomy of XML (5) DTD - Document Type Definition DTD - Document Type Definition Defines the permitted elements, attributes and the hierarchy among them Defines the permitted elements, attributes and the hierarchy among them http://library.ust.hk/xmlworkshop/xml1/bookstore.dtd http://library.ust.hk/xmlworkshop/xml1/bookstore.dtd http://library.ust.hk/xmlworkshop/xml1/bookstore.dtd “Well-formed” - XML that is properly tagged “Well-formed” - XML that is properly tagged “Valid” - properly tagged and conforms to a DTD “Valid” - properly tagged and conforms to a DTD XML can be well-formed and still not valid. XML can be well-formed and still not valid.

13 Hong Kong University of Science & Technology Library Anatomy of XML (6) XML Schema XML Schema Adds data types, such as number, date, time, etc. and permits user-defined data types. Adds data types, such as number, date, time, etc. and permits user-defined data types. Written in XML Written in XML Example: Example: http://library.ust.hk/xmlworkshop/xml1/bookstore- schema.html http://library.ust.hk/xmlworkshop/xml1/bookstore- schema.html http://library.ust.hk/xmlworkshop/xml1/bookstore- schema.html http://library.ust.hk/xmlworkshop/xml1/bookstore- schema.html

14 Hong Kong University of Science & Technology Library Anatomy of XML (7) XSL - eXtensible Style Sheet Language XSL - eXtensible Style Sheet Language Specifies presentation of a class of XML files by using XSLT to describe how an instance of the class is transformed - e.g. into HTML Specifies presentation of a class of XML files by using XSLT to describe how an instance of the class is transformed - e.g. into HTML Uses XPOINTER, XPATH, and XSLT Uses XPOINTER, XPATH, and XSLT XPATH XPATH for addressing parts of an XML document for addressing parts of an XML document XPOINTER XPOINTER pointing to part of an external or remote XML file pointing to part of an external or remote XML file XSLT XSLT for transforming XML files into other XML files for transforming XML files into other XML files

15 Hong Kong University of Science & Technology Library Anatomy of XML (8) XQUERY - XML Query Language XQUERY - XML Query Language for querying XML Fragments/Documents for querying XML Fragments/Documents Can express queries across many kinds of data, whether physically stored in XML or viewed as XML via middleware (in text files, object repositories, relational databases, etc.) Can express queries across many kinds of data, whether physically stored in XML or viewed as XML via middleware (in text files, object repositories, relational databases, etc.)

16 Hong Kong University of Science & Technology Library Why is XML important for Library Applications? Most library metadata is hierarchical in nature, not relational Most library metadata is hierarchical in nature, not relational XML is particularly well-suited for marking up full-text data XML is particularly well-suited for marking up full-text data Many emerging XML-based standards are driven by the library and information professions, e.g. Dublin Core, EAD Many emerging XML-based standards are driven by the library and information professions, e.g. Dublin Core, EAD

17 Hong Kong University of Science & Technology Library XML/Library References (1) Books Books The ABCs of XML : the librarian's guide to the eXtensible markup language / by Norman Desmarais The ABCs of XML : the librarian's guide to the eXtensible markup language / by Norman Desmarais The ABCs of XML : the librarian's guide to the eXtensible markup language The ABCs of XML : the librarian's guide to the eXtensible markup language [The Appendices of this book mention HKUST's early (1998) proposal/discussion of marking up MARC in XML.] [The Appendices of this book mention HKUST's early (1998) proposal/discussion of marking up MARC in XML.] XML in libraries / edited by Roy Tennant XML in libraries / edited by Roy Tennant XML in libraries XML in libraries Putting XML to work in the library / Dick R. Miller and Kevin S. Clarke Putting XML to work in the library / Dick R. Miller and Kevin S. Clarke Putting XML to work in the library Putting XML to work in the library

18 Hong Kong University of Science & Technology Library XML/Library References (2) Online Resources Online Resources Getting Started with XML by Eric Morgan Getting Started with XML by Eric Morgan http://www.infomotions.com/musings/getting-started/ How Does XML Help Libraries? How Does XML Help Libraries? http://www.infotoday.com/cilmag/sep02/Banerjee.htm Practical XML & XSLT by Roy Tenant Practical XML & XSLT by Roy Tenant http://escholarship.cdlib.org/rtennant/presentations/2003il/xml XML Cover Pages XML Cover Pages http://xml.coverpages.org/xml.html XML4LIB Discussion List XML4LIB Discussion List http://sunsite.berkeley.edu/XML4Lib/ XML in 10 Points XML in 10 Points http://www.w3.org/XML/1999/XML-in-10-points

19 Hong Kong University of Science & Technology Library Key Library Players & Projects Medlane’s MarcXML project http://xmlmarc.stanford.edu/ Medlane’s MarcXML project http://xmlmarc.stanford.edu/ http://xmlmarc.stanford.edu/ LC ( U.S. Library of Congress ) http://www.loc.gov/standards/marcxml/ LC ( U.S. Library of Congress ) http://www.loc.gov/standards/marcxml/ http://www.loc.gov/standards/marcxml/ OCLC http://www.oclc.org/research/projects/ OCLC http://www.oclc.org/research/projects/ http://www.oclc.org/research/projects/ AusLit http://www.auslit.edu.au/ AusLit http://www.auslit.edu.au/ http://www.auslit.edu.au/ Local projects Local projects Open University of HK Library - eText Center Open University of HK Library - eText Center http://www.lib.ouhk.edu.hk/etext/frame_2.html HKUST - XML Global Name Access Control Repository HKUST - XML Global Name Access Control Repository http://library.ust.hk/info/nac/ And many many others … And many many others … http://dir.yahoo.com/Reference/Libraries/Digital_Libraries/


Download ppt "Updated 2003.11.14 10:02 Hong Kong University of Science & Technology Library Workshop on XML-Based Library Applications 1. What is XML?"

Similar presentations


Ads by Google