Title: Transforming XML Schema to Conceptual XML
1Transforming XML Schema to Conceptual XML
- Reema Al-Kamha
- Spring Research Conference
-
Supported by NSF
2Motivation
- XML is becoming standard for data representation.
- XML Schema defines the structure of XML
documents. - XML Schema has a textual representation.
- There is a need to conceptualize XML Schema.
-
3 4XML Schema Components
- The element element
- The attribute element
- The simpleType element
- The complexType element
- The attributeGroup element
- The choice, and sequence elements
5Choice Translation
ltxselement name"Phone"gt
ltxscomplexTypegt
ltxschoice minOccurs"1" maxOccurs"1"gt
ltxselement
name"HomePhone" type"xsstring" minOccurs"1"
maxOccurs"1"/gt
ltxselement name"CellPhone" type"xsstring"/gt
lt/xschoicegt
lt/xscomplexTypegt
lt/xselementgt
6Sequence Translation
ltxselement name "Document gt
ltxscomplexTypegt ltxssequence
minOccurs"1" maxOccurs "100"gt
ltxselement ref"Employee" /gt
lt/xssequencegt
lt/xscomplexTypegt ....................
lt/xselementgt ltxselement name"Employee"gt
ltxscomplexTypegt
ltxssequencegt ltxselement
name"Name" type"NameType"/gt
ltxselement name"Phone"/gt
lt/xssequencegt .
lt/xscomplexTypegt lt/xselementgt
..
. ltxscomplexType
name"NameType"gt ltxssequencegt
ltxselement
name"FirstName" type"xsstring" minOccurs"1"
maxOccurs"1"/gt
ltxselement name"MiddleName" type"xsstring"
minOccurs"0" maxOccurs"2"/gt
ltxselement name"LastName"
type"xsstring" minOccurs"1" maxOccurs"1"/gt
lt/xssequencegt
lt/xscomplexTypegt lt/xselementgt
7Attribute AttributeGroup Translation
ltxselement name"Employee"gt
ltxscomplexTypegt ltxssequencegt
...................
lt/xssequencegt ltxsattribute
name"EmployeeNumber" type "xsstring"
use"required" /gt ltxsattributeGroup
ref"EmployeeAttribute" /gt
lt/xscomplexTypegt lt/xselementgt
ltxsattributeGroup name"EmployeeAttribute" gt
ltxsattribute ref"Status" use"optional" /gt
ltxsattribute name"Language"
type"LanguageType" /gt lt/xsattributeGroupgt
ltxsattribute name"Status"
type"xsstring" /gt ltxssimpleType
name"LanguageType" gt ltxsrestriction
base"xsstring" gt ltxsenumeration
value"English" /gt ltxsenumeration
value"Latin" /gt lt/xsrestrictiongt
lt/xssimpleTypegt
8Key Constraint Translation
ltxselement name "Document"gt
ltxscomplexTypegt
lt/xscomplexTypegt
ltxskey name "AKey"gt ltxsselector
xpath ".//Employee" /gt ltxsfield
xpath "_at_EmployeeNumber"/gt lt/xskeygt
lt/xselementgt
9SubstitutionGroup Translation
ltxselement name"FullTimeEmployee"
substitutionGroup"Employee"/gt
10Translation Result
11 12 13 14 15 16 17Contribution
- A vision for conceptualize XML Schema
- Implement the transformation from XML Schema to
C-XML