Commit | Line | Data |
---|---|---|
d44e3c4f | 1 | /****************************************************************************** |
2 | * Copyright (c) 2000-2016 Ericsson Telecom AB | |
970ed795 EL |
3 | * |
4 | * XSD to TTCN-3 Translator | |
5 | * | |
6 | * All rights reserved. This program and the accompanying materials | |
7 | * are made available under the terms of the Eclipse Public License v1.0 | |
8 | * which accompanies this distribution, and is available at | |
9 | * http://www.eclipse.org/legal/epl-v10.html | |
d44e3c4f | 10 | * |
11 | * Contributors: | |
12 | * Balasko, Jeno | |
13 | * Lovassy, Arpad | |
14 | * Raduly, Csaba | |
15 | * Szabo, Bence Janos | |
16 | * | |
17 | ******************************************************************************/ | |
970ed795 EL |
18 | // |
19 | // File: www_XmlTest_org_complex_restriction_e.ttcn | |
20 | // Description: | |
21 | // References: | |
22 | // Rev: | |
23 | // Prodnr: | |
24 | // Updated: Thu Sep 5 17:35:03 2013 | |
25 | // Contact: http://ttcn.ericsson.se | |
26 | // | |
27 | //////////////////////////////////////////////////////////////////////////////// | |
28 | // Generated from file(s): | |
29 | // - XmlTest_complex_restriction.xsd | |
30 | // /* xml version = "1.0" */ | |
31 | // /* targetnamespace = "www.XmlTest.org/complex_restriction" */ | |
32 | //////////////////////////////////////////////////////////////////////////////// | |
33 | // Modification header(s): | |
34 | //----------------------------------------------------------------------------- | |
35 | // Modified by: | |
36 | // Modification date: | |
37 | // Description: | |
38 | // Modification contact: | |
39 | //------------------------------------------------------------------------------ | |
40 | //////////////////////////////////////////////////////////////////////////////// | |
41 | ||
42 | ||
43 | module www_XmlTest_org_complex_restriction_e { | |
44 | ||
45 | ||
46 | import from XSD all; | |
47 | ||
48 | ||
49 | /* This documentum tests based on | |
50 | XML Schema Part 0: Primer Second Edition | |
51 | 4.4 Deriving Types by Restriction | |
52 | XML Schema Part 1: Structures Secod Edition | |
53 | 3.4.2 XML Representation of Complex Type Definitions */ | |
54 | ||
55 | ||
56 | type record MySubjects4 | |
57 | { | |
58 | XSD.GYear year optional, | |
59 | XSD.String english optional, | |
60 | XSD.String math optional, | |
61 | record length(0 .. 3) of XSD.String physics_list, | |
62 | XSD.String chemistry optional | |
63 | } | |
64 | with { | |
3f84031e | 65 | variant (year) "name as capitalized"; |
66 | variant (year) "attribute"; | |
67 | variant (english) "name as capitalized"; | |
68 | variant (math) "name as capitalized"; | |
69 | variant (physics_list) "untagged"; | |
70 | variant (physics_list[-]) "name as 'Physics'"; | |
71 | variant (chemistry) "name as capitalized"; | |
970ed795 EL |
72 | }; |
73 | ||
74 | ||
75 | type record MySubjects4Restriction | |
76 | { | |
77 | XSD.GYear year optional, | |
78 | XSD.String english, | |
79 | XSD.String math, | |
80 | record length(1 .. 2) of XSD.String physics_list | |
81 | } | |
82 | with { | |
3f84031e | 83 | variant (year) "name as capitalized"; |
84 | variant (year) "attribute"; | |
85 | variant (english) "name as capitalized"; | |
86 | variant (math) "name as capitalized"; | |
87 | variant (physics_list) "untagged"; | |
88 | variant (physics_list[-]) "name as 'Physics'"; | |
970ed795 EL |
89 | }; |
90 | ||
91 | ||
92 | } | |
93 | with { | |
3f84031e | 94 | encode "XML"; |
95 | variant "namespace as 'www.XmlTest.org/complex_restriction' prefix 'ns36'"; | |
96 | variant "controlNamespace 'http://www.w3.org/2001/XMLSchema-instance' prefix 'xsi'"; | |
970ed795 | 97 | } |