Presentation is loading. Please wait.

Presentation is loading. Please wait.

XMLSchema to TTCN-3 Mapping Importing XML schema based data types into TTCN-3.

Similar presentations


Presentation on theme: "XMLSchema to TTCN-3 Mapping Importing XML schema based data types into TTCN-3."— Presentation transcript:

1 XMLSchema to TTCN-3 Mapping Importing XML schema based data types into TTCN-3

2 ETSI MTS #40, Berlin, Mar 2005 © FOKUS (2005) Importing XMLSchema based Datatypes into TTCN-3 Overview XMLSchema built-in datatypes XMLSchema data type components Examples

3 ETSI MTS #40, Berlin, Mar 2005 © FOKUS (2005) Overview TTCN-3 core notation ASN.1 Types and Values IDL Interfaces and Types XMLSchema Types Other Types & Values Tabular Format Graphical Format Other Presentation Formats Plain Text TTCN-3 User

4 ETSI MTS #40, Berlin, Mar 2005 © FOKUS (2005) XMLSchema BuiltIn Types I anyType anySimpleType durationdateTimetimedate gYearMonthgYeargMonthDaygDaygMonth boolean base64Binary hexBinaryfloatdoubleanyURIQNameNOTATION all complex types stringdecimal integer long int short byte nonNegativeInteger nonPositiveInteger negativeInteger unsignedLong unsignedInt unsignedShort normalizedString token language Name NMToken NCName NMTokens positiveInteger unsignedByte EntityIDREF ID EntitiesIDREFS primitive types derived by restrictions derived by lists hexstring charstring type integer positiveInteger (0.. infinity) type set of NMToken NMTokens float

5 ETSI MTS #40, Berlin, Mar 2005 © FOKUS (2005) XMLSchema Build-in Types II XSDAUX.ttcn3 module XSDAUX { /* 1.string */ type charstring string; /* 2.boolean */ type integer bitXSD(1,0); type union booleanXSD { bitXSD bit, boolean bool } /* 3.decimal */ type float decimal;..... }

6 ETSI MTS #40, Berlin, Mar 2005 © FOKUS (2005) XMLSchema datatype components minInclusive, maxExclusive pattern, enumeration, length... schema all list sequence choice groupattributecomplexType element include importsimpleTypeattributeGroup attribute attributeGroup restriction union complexContent all choice sequence simpleContent extension restriction extension group attribute attributeGroup allchoice sequencegroupattribute attributeGroup simpleTypefacets minInclusive, maxExclusive pattern, enumeration, length... attributeattributeGroup set union record union set of … record, union or set facets Subtype definition with length, or list restrictions. Ex: Type_string.ttcn3 Subtype definition with length, or list restrictions. Ex: Type_string.ttcn3

7 ETSI MTS #40, Berlin, Mar 2005 © FOKUS (2005) Example type union cust__Global_Group { XSDAUX.string e1, XSDAUX.string e2, XSDAUX.string e3, XSDAUX.string e4 } type record SEQUENCE__1 { cust__Global_Group sequence__1, XSDAUX.byte E } type union CHOICE__2 { SEQUENCE__1 choice__1, XSDAUX.int E } type charstring A__Attribute__1 with {extension "Attribute"}; type set ORDER { CHOICE__2 choice, A__Attribute__1 A optional } XMLSchema TTCN-3

8 ETSI MTS #40, Berlin, Mar 2005 © FOKUS (2005) The Work Done Initial work by FOKUS in internal research and diploma thesis, 2002-2004 Discussion of mapping in the TTmedal consortium, 2003-now Implementation and case studies Draft prepared, March 2005 Face-to-face meeting, March 2005

9 ETSI MTS #40, Berlin, Mar 2005 © FOKUS (2005) The Document 1Scope1Scope 2References2References 3Abbreviations3Abbreviations 4Approach4Approach 5Mapping XSD Schemas5Mapping XSD Schemas 6Ignored schema components and properties6Ignored schema components and properties 7TTCN-3 module and namespaces7TTCN-3 module and namespaces 8Name conversion8Name conversion 9Mapping of built-in data types9Mapping of built-in data types 10 Mapping of data type components10 Mapping of data type components Annex A (normative): Mapping of Built-In TypesAnnex A (normative): Mapping of Built-In Types Annex B (normative): XSDAUX.ttcn3Annex B (normative): XSDAUX.ttcn3 Annex C (informative): ReferencesAnnex C (informative): References Annex D (informative): ExamplesAnnex D (informative): Examples

10 ETSI MTS #40, Berlin, Mar 2005 © FOKUS (2005) Contributors/Reviewers FOKUS NetHawk Nokia Fraunhofer ESK University of Göttingen

11 ETSI MTS #40, Berlin, Mar 2005 © FOKUS (2005) XML Meeting Review of the draft Discussion what to do with non supported features support for XML values

12 ETSI MTS #40, Berlin, Mar 2005 © FOKUS (2005) One issue for all mapping documents Name clashes with TTCN-3 keywords Consistent resolving rules for all mappings would be helpful Proposal to use a _ postfix together with an extension attribute indicating the original name i.e. type boolean boolean_ with { extension "XSD:boolean" }

13 ETSI MTS #40, Berlin, Mar 2005 © FOKUS (2005) Further TTCN-3 extensions?! Pattern for float and integer Length for integer (number of decimal digits) Different lengths for float (number of fractional digits, etc.) ? min and max facets of XML directly added to TTCN-3 for string types, integer and float ? whitspace facets for string types ? a more generic approach to subtyping with facets could be useful

14 ETSI MTS #40, Berlin, Mar 2005 © FOKUS (2005) Timing Completion till Oct. 2005 Adoption for ETSI MTS #41


Download ppt "XMLSchema to TTCN-3 Mapping Importing XML schema based data types into TTCN-3."

Similar presentations


Ads by Google