Title: XML Technologies
1XML Technologies
- Getting data to play nice with other data
2Introduction
- Enormous amount of topics and subtopics
- Standards
- Popular and important implementations of XML
- Concentrate on XML Data- highly structured side
of XML
3XML Data
- What is it
- What can it do
- Creation
- Validation
- Presentation
4XML Data
lt?xml version"1.0"?gt lt?xml-stylesheet
type"text/xsl" href"license.xsl"?gt ltlicense
uniqueid"105"gt ltlictitlegtNurse,
Registeredlt/lictitlegt ltlicdescgtRegistered
Nurses (RNs) administer general nursing care
which includes assessing, planning,
providing, delegating, teaching, and supervising
care which promotes optimum health
and independence for ill, injured, and well
persons. They give prescribed medications and
treatments, and may supervise other
nursing personnel. lt/licdescgt
ltauth-statutegtORS 678.010 to 678.135lt/auth-statute
gt ltsocgt ltsoccodegt291111lt/soccodegt
lt/socgt ltcipgt ltcipcodegt511601lt/cipcodegt
ltcipcodegt511602lt/cipcodegt ltcipcodegt511603lt/ci
pcodegt ltcipcodegt511604lt/cipcodegt ltcipcodegt511605
lt/cipcodegt ltcipcodegt010606lt/cipcodegt ltcipcodegt51
1606lt/cipcodegt ltcipcodegt511607lt/cipcodegt ltcipcod
egt511608lt/cipcodegt ltcipcodegt511609lt/cipcodegt ltci
pcodegt511610lt/cipcodegt ltcipcodegt511611lt/cipcodegt
ltcipcodegt511612lt/cipcodegt lt/cipgt
ltlic-requirementsgt ltrequirementgtBe able to
read and write legiblylt/requirementgt
ltrequirementgtBe at least 18 years of
agelt/requirementgt ltrequirementgtBe free of
communicable diseaseslt/requirementgt
lt/lic-requirementsgt ltfeesgt
ltexam-feegt120lt/exam-feegt
ltoriginal-license-feegt80lt/original-license-feegt
ltrenewal-feegt65lt/renewal-feegt lt/feesgt
ltnumber-of-licensesgt277lt/number-of-licensesgt lt/lic
ensegt
- What is it?
- XML identifies structure
- Helps give meaning to data
- Glue that binds many applications together
- Way of representing information as text documents
5XML Data
- What can it do?
- Move data around
- Way to make the data platform independent
- Kind of like an executive summary or an outline-
Can pull data from multiple sources (even tables
in a database) into a human readable, ordered - Represent data in a hierarchy
- Data Centric XML vs. Document Centric XML
- Relational databases store data in normalized
tables - XML documents can be created from Relational
Database queries - XML documents can be stored in Relational
Databases - Native XML Databases also available
- Relational Databases with native XML support
6XML Data
- Creating XML Data
- Any tags be used
- XML defines a rigid set of rules for the syntax
of markup tags - Text editor
- XML Tools
- Databases
- And More
7XML Data
- Validating XML Data
- DTD, Schema
- Elements are nested, attributes they can have and
values they can contain - The names of tags and how they are used is left
up to the user or application and can be enforced
by - Document Type Definitions (DTDs)
- XML Schema
- Other Alternatives Relax NG etc.
lt!ELEMENT license (lictitle, licdesc,
number-of-licenses?, places-of-employment?,
auth-statute?, lic-requirements?, fees?, exam?,
licensing-agency?, cistitle?, dot?, soc?,
cip?)gt lt!ATTLIST license uniqueid ID
REQUIREDgt lt!ELEMENT lictitle (PCDATA)gt lt!ELEMENT
licdesc (PCDATA)gt lt!ELEMENT number-of-licenses
(PCDATA)gt lt!ELEMENT places-of-employment
(PCDATA)gt lt!ELEMENT auth-statute (PCDATA)gt DTD
lt?xml version"1.0" encoding"UTF-8"?gt ltxsschema
xmlnsxs"http//www.w3.org/2001/XMLSchema"gt ltxse
lement name"license"gt ltxscomplexTypegt
ltxssequencegt ltxselement ref"lictitle"/gt
ltxselement ref"licdesc"/gt ltxselement
minOccurs"0" ref"number-of-licenses"/gt ltxselem
ent minOccurs"0" ref"places-of-employment"/gt ltx
selement minOccurs"0" ref"auth-statute"/gt ltxs
element minOccurs"0" ref"lic-requirements"/gt ltx
selement minOccurs"0" ref"fees"/gt ltxselement
minOccurs"0" ref"exam"/gt ltxselement
minOccurs"0" ref"licensing-agency"/gt ltxselemen
t minOccurs"0" ref"cistitle"/gt ltxselement
minOccurs"0" ref"dot"/gt ltxselement
minOccurs"0" ref"soc"/gt ltxselement
minOccurs"0" ref"cip"/gt lt/xssequencegt
ltxsattribute name"uniqueid" type"xsID"
use"required"/gt lt/xscomplexTypegt lt/xselementgt
Schema
8XML Data
/ license xml casstyle sheet / license
font-family Helvetica, Arial, Verdana,
sans-serif font-size 11pt
margin-top 12pt margin-left 12pt
margin-bottom 4pt lictitle, licdesc,
number-of-licenses, places-of-employment,
auth-statute, lic-requirements,
fees, exam-fee, original-license-fee
, renewal-fee, exam,
licensing-agency, cistitle,
dot, soc, cip display
block font-family
Helvetica, Arial, Verdana, sans-serif
font-size 11pt
margin-top 12pt margin-left
12pt margin-bottom
4pt auth-statutebefore content "Authorizing
Statue " font-weightbold socbefore
content "SOC Codes " font-weightbold dotb
efore content "DOT Codes "
font-weightbold cipbefore content "CIP
Codes " font-weightbold lictitle display
block font-family Verdana, Arial,
Helvetica, sans-serif font-size
20px font-weight bold
color 336600 padding-top 35px
text-aligncenter
margin-top 12pt CSS
lt?xml version'1.0'?gt ltxslstylesheet
xmlnsxsl"http//www.w3.org/1999/XSL/Transform"
version"1.0"gt ltxsltemplate match"/"gt
ltHTMLgt ltSTYLEgt dd text-align center
body font-family Helvetica, Arial, Verdana,
sans-serif font-size
11pt .title font-family Verdana, Arial,
Helvetica, sans-serif font-size
20px font-weight bold
color 336699 padding-top
35px lt/STYLEgt ltBODYgt
ltcenter class"title"gtltxslvalue-of
select"license/lictitle"/gtlt/centergt
ltbr/gt ltpgtltxslvalue-of
select"license/licdesc"/gtlt/pgt
ltpgtltbgtAuthorizing Statute lt/bgt
ltxslvalue-of select"license/auth-statute"/gtlt/pgt
ltpgtltbgtSOC Codes lt/bgt
ltxslfor-each select"license/soc/soccode"gt
ltxslif test"position() gt
1"gt,lt/xslifgt 160 ltxslvalue-of select"."/gt
lt/xslfor-eachgt lt/pgt
XSL
- Displaying XML Data on the Web
- Cascading Style Sheets (CSS), simple, preferred
choice (non XML structure) - Extensible Style Sheet Language (XSL), more
complex formatting (XML structure) - These two technologies can be used as alternative
methods of formatting an XML document or they can
work together - Examples
- CSS
- XSL
9XML Data Applications
- Information Sharing (RSS, ATOM, RDF)
- Data Sharing (Namespaces and XSLT)
- Application Integration (Web Services)
- Information Aggregation (MS Office)
- Data Integration (XML and Databases)
10XML Data Applications
- Information Syndication
- Federal government using RSS
- State government using RSS
- Growing number of users consuming RSS
11XML Data Applications
- Data Sharing
- Delivery of structured information that can be
manipulated - Namespaces
- distinguish different elements and attributes
that have the same name but different meaning - groups all the elements and attributes together
- XSLT to translate one XML format to another
- ltlicense
- xmlns22http//www.almisdb.org/ns/license21/1.5
- xmlns23http//www.almisdb.org/ns/license23/1.0
gt - Namespaces
- ltxslstylesheet xmlns xslhttp//www.w3.org/1999
/XSL/Transform - version1.0gt
- ltxsltemplate matchlictitlegt
- ltxslapply-templates/gt
- lt/xsltemplategt
- lt/xslstylesheetgt
- XSLT
12XML Data Applications
- Application Integration
- Web Services
- Key components- XML, HTTP, SOAP, WSDL, UDDI
- still at early stages EXCEPT for RSS
- Major chunks
- Building web services i.e. I have one
- Publishing web services i.e. I want one Or I want
to let others know I have one - Consuming Web Services i.e. I get one
-
If computers get too powerful, we can organize
them into a committee -- that will do them in.
Bradley's Bromide
13XML Data Applications
- Data Integration
- XML and databases
- Data residing in different platforms
- Customized data formats
- Desired information normally resides in multiple
databases - Even can span across states
- Xquery/Xpath
- View raw results with a browser
14XML Data Applications
- Information Aggregation
- XML and MS Office
- Share data across software applications including
desktop applications - View raw results with a browser
15XML Technology Watch
- Top 5 things to watch for as relate to XML Data
- Semantic Web
- What it is Way to give full meaning to XML
elements using inheritance relationships - Reason to watch W3C project, Make better
searching for relevant information - RDF
- What it is Way to describe resources especially
Web documents and sites - Reason to watch W3C project, Representing
normalized data, (Xml topic maps) capture a lot
of basic infrastructure for data, Support is
growing - Web Ontologies (OWL)
- What it is Means of representing complex
information - Reason to watch More detail on relationships
than RDF, can express cardinality restraints - XQuery
- What it is Uses SQL-like query language,
combined with XPATH expressions for querying XML
documents - Reason to watch Full query and reporting from
XML documents, May replace primitive searching
and querying of XML done by XSLT - MetaData