The XML Language.

Slides:



Advertisements
Similar presentations
Introduction to the Logical Structure of XML Documents Web Engineering, SS 2007 Tomáš Pitner, Michael Derntl.
Advertisements

SPECIAL TOPIC XML. Introducing XML XML (eXtensible Markup Language) ◦A language used to create structured documents XML vs HTML ◦XML is designed to transport.
© De Montfort University, XML – a meta language Howell Istance and Peter Norris School of Computing De Montfort University.
3 November 2008CIS 340 # 1 Topics To define XML as a technology To place XML in the context of system architectures.
Introduction to XLink Transparency No. 1 XML Information Set W3C Recommendation 24 October 2001 (1stEdition) 4 February 2004 (2ndEdition) Cheng-Chia Chen.
A Technical Introduction to XML Transparency No. 1 XML quick References.
XML: New or Old? XML was not an extention of HTML That already existed! SGML (ISO 8879) XML was a simplification of SGML  80 / 20 rule  (80% of the features.
Thayer School of Engineering Dartmouth Lecture 2 Overview Web Services concept XML introduction Visual Studio.net.
XML(EXtensible Markup Language). XML XML stands for EXtensible Markup Language. XML is a markup language much like HTML. XML was designed to describe.
XML Primer. 2 History: SGML vs. HTML vs. XML SGML (1960) XML(1996) HTML(1990) XHTML(2000)
XML Basics Hope Greenberg Center for Teaching & Learning.
Copyright © 2003 Pearson Education, Inc. Slide 2-1 Created by Cheryl M. Hughes, Harvard University Extension School — Cambridge, MA The Web Wizard’s Guide.
XML introduction to Ahmed I. Deeb Dr. Anwar Mousa  presenter  instructor University Of Palestine-2009.
XML Anisha K J Jerrin Thomas. Outline  Introduction  Structure of an XML Page  Well-formed & Valid XML Documents  DTD – Elements, Attributes, Entities.
XML: Overview MIS 181.9: Service Oriented Architecture 2 nd Semester,
XP 1 CREATING AN XML DOCUMENT. XP 2 INTRODUCING XML XML stands for Extensible Markup Language. A markup language specifies the structure and content of.
XML Technologies Surekha Akula
XML A Single Entity. xml a single entity Objectives Objectives :  understand the data model  describe the XML Document  describe the XML Schema  describe.
XML - DTD. The building blocks of XML documents Elements, Tags, Attributes, Entities, PCDATA, and CDATA.
XML 1 Enterprise Applications CE00465-M XML. 2 Enterprise Applications CE00465-M XML Overview Extensible Mark-up Language (XML) is a meta-language that.
August Chapter 2 - Markup and Core Concepts Learning XML by Erik T. Ray Slides were developed by Jack Davis College of Information Science and Technology.
What is XML?  XML stands for EXtensible Markup Language  XML is a markup language much like HTML  XML was designed to carry data, not to display data.
 XML is designed to describe data and to focus on what data is. HTML is designed to display data and to focus on how data looks.  XML is created to structure,
Processing of structured documents Spring 2002, Part 2 Helena Ahonen-Myka.
Tutorial 1: XML Creating an XML Document. 2 Introducing XML XML stands for Extensible Markup Language. A markup language specifies the structure and content.
Electronic Commerce COMP3210 Session 4: Designing, Building and Evaluating e-Commerce Initiatives – Part II Dr. Paul Walcott Department of Computer Science,
How do I use HTML and XML to present information?.
XML 2nd EDITION Tutorial 1 Creating An Xml Document.
VICTORIA UNIVERSITY OF WELLINGTON Te Whare Wananga o te Upoko o te Ika a Maui SWEN 432 Advanced Database Design and Implementation An Introduction to XML.
XML Documents Chao-Hsien Chu, Ph.D. School of Information Sciences and Technology The Pennsylvania State University Elements Attributes Comments PI Document.
Introduction to XML This presentation covers introductory features of XML. What XML is and what it is not? What does it do? Put different related technologies.
XML Instructor: Charles Moen CSCI/CINF XML  Extensible Markup Language  A set of rules that allow you to create your own markup language  Designed.
XP 1 Creating an XML Document Developing an XML Document for the Jazz Warehouse XML Tutorial.
17 Apr 2002 XML Syntax: Documents Andy Clark. Basic Document Structure Element tags – Elements have associated attributes Text content Miscellaneous –
Lecture 16 Introduction to XML Boriana Koleva Room: C54
1 Introduction to XML XML stands for Extensible Markup Language. Because it is extensible, XML has been used to create a wide variety of different markup.
An Introduction to XML Sandeep Bhattaram
XML Introduction. What is XML? XML stands for eXtensible Markup Language XML stands for eXtensible Markup Language XML is a markup language much like.
What it is and how it works
XML Design Goals 1.XML must be easily usable over the Internet 2.XML must support a wide variety of applications 3.XML must be compatible with SGML 4.It.
XML Basics A brief introduction to XML in general 1XML Basics.
1 Tutorial 11 Creating an XML Document Developing a Document for a Cooking Web Site.
225 City Avenue, Suite 106 Bala Cynwyd, PA , phone , fax presents… XML Syntax v2.0.
Well Formed XML The basics. A Simple XML Document Smith Alice.
What is XML? eXtensible Markup Language eXtensible Markup Language A subset of SGML (Standard Generalized Markup Language) A subset of SGML (Standard Generalized.
XML CSC1310 Fall HTML (TIM BERNERS-LEE) HyperText Markup Language  HTML (HyperText Markup Language): December  Markup  Markup is a symbol.
Evaluation Biztalk Table of Contents Introduction to XML. Anatomy of an XML document. What is an XML Schema? What is SOAP? XML Web Services overview.
XML CORE CSC1310 Fall XML DOCUMENT XML document XML document is a convenient way for parsers to archive data. In other words, it is a way to describe.
C Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Introduction to XML Standards.
Introduction to XML Kanda Runapongsa Dept. of Computer Engineering Khon Kaen University.
Jackson, Web Technologies: A Computer Science Perspective, © 2007 Prentice-Hall, Inc. All rights reserved Chapter 7 Representing Web Data:
XML Extensible Markup Language
PART 1 XML Basics. Slide 2 Why XML Here? You need to understand the basics of XML to do much with Android All of they layout and configuration files are.
XML Introduction to XML Extensible Markup Language.
HTML is about making documents. Simple Code for Simple Layout My Document This is an example HTML document First paragraph Second paragraph This is the.
Extensible Markup Language (XML) Pat Morin COMP 2405.
XML intro. What is XML? XML stands for EXtensible Markup Language XML is a markup language much like HTML XML was designed to carry data, not to display.
XML BASICS and more…. What is XML? In common:  XML is a standard, simple, self-describing way of encoding both text and data so that content can be processed.
Unit 4 Representing Web Data: XML
Hope Greenberg Center for Teaching & Learning
Extensible Markup Language XML
Extensible Markup Language XML
Chapter 7 Representing Web Data: XML
Creating an XML Document
More Sample XML By Sadia Anjum.
Javascript & jQuery XML.
What is XML?.
Allyson Falkner Spokane County ISD
Review of XML IST 421 Spring 2004 Lecture 5.
XML IST 421.
Presentation transcript:

The XML Language

Overview XML is a very simple language The entire specification is only about 35 printed pages This includes the specification for DTDs

The Golden Rule XML IS CASE SENSITIVE

The XML Document At the heart of XML is the XML document An XML document is a logical entity rather than a physical one One logical document can be stored in different physical files locally and on the Web A well-formed subset of an XML document is called a document fragment An XML document contains markup (tags) and data

The XML Document (Contents) Elements Entity declarations and entity references Processing instructions Unparsed character data (CDATA) Comments

Elements (Introduction) XML tags resemble HTML tags but they are not predefined That is, you give names to tags just as you give names to variables and other identifiers Starting tags appear as <tag> Ending tags appear as </tag> Empty elements (elements without data) can appear as <tag /> XML elements MUST have an ending tag A starting and ending tag (along with any text) makes up an element

Elements (Content) An element can have different types of content If an element contains other (nested) elements, it has element content If an element contains text and other nested elements, the element has mixed content If an element contains only data, then the element has simple content Elements can also have 0, 1, or many attributes

Elements (Simple Content) <?xml version="1.0" encoding="utf-8" ?> <!-- What is the answer? --> <universe> <question/> <answer> 42 <!-- It's 42. --> </answer> </universe> <answer> has simple content (data and no child elements)

Elements (Mixed Content) <?xml version="1.0" encoding="utf-8" ?> <!-- What is the answer? --> <universe> <question/> <answer> 42 <!-- It's 42. --> </answer> </universe> <universe> has mixed content (nested elements and data)

Elements (Nesting) Elements can be nested These are hierarchical nodes Elements MUST be nested correctly though A child element must completely reside in its parent element There must be exactly one and only one root element

Elements (Nesting – Example) <?xml version="1.0" encoding="utf-8" ?> <!-- What is the answer? --> <universe> <answer> 42 <!-- It's 42. --> </answer> </universe> Root element is <universe> Nested element is <answer>

Illegal Element Nesting (Example) The following nesting is illegal: <?xml version="1.0" encoding="utf-8" ?> <!-- What is the answer? --> <universe> <answer> 42 <!-- It's 42. --> </universe> </answer>

(The Document Prolog – Example) The following is an XML prolog declaration The XML version is 1.0 The character encoding scheme is “UTF-8” The document does not reference any external documents While the following looks like a tag with three attributes, it is not <?xml version="1.0" encoding=“UTF-8" standalone="yes"?>

XML Attributes (Example) In the following example, id and size are attributes of the <universe> element <?xml version="1.0" encoding="utf-8" ?> <universe id="1" size="Infinite"> <answer>42</answer> </universe>

Comparing Attributes and Elements The following 2 documents are (roughly) equivalent <?xml version="1.0" encoding="utf-8" ?> <student id="12345"> <name>Bill</name> </student> <?xml version="1.0" encoding="utf-8" ?> <student> <id>12345</id> <name>Bill</name> </student>

XML Comments (Example) The following document contains comments <?xml version="1.0" encoding="utf-8" ?> <!-- What is the answer? --> <universe> <answer> 42 <!-- It's 42. --> </answer> </universe>

The XML Document Tree Well-formed XML documents are represented as a tree-based structure For any given document, there exists exactly one document tree The same genealogical terms are used to describe XML trees as other trees

Entities (Introduction) Entities are part of the XML Recommendation Think of entities as macro expanders placeholders The XML specification uses the term storage unit to describe an entity I think of entities as a “macro expander” or global search and replace way of importing files

Entities (Classification) Parsed Unparsed General Parameter External Internal External Internal External Named Numbered Predefined

Predefined Entities (Internal Parsed) Markup characters such as “<“ or “>” must sometimes be treated as literal data That is, these ‘special’ characters should not be parsed For this, XML supplies the following predefined entities & & < < > > &apos; ‘ " “