Sync with 5.4.2
[deliverable/titan.core.git] / regression_test / XML / XmlWorkflow / XmlTest_expectedTtcns / www_XmlTest_org_union_e.ttcn
1 /*******************************************************************************
2 * Copyright Ericsson Telecom AB
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
10 *******************************************************************************/
11 //
12 // File: www_XmlTest_org_union_e.ttcn
13 // Description:
14 // References:
15 // Rev:
16 // Prodnr:
17 // Updated: Thu Sep 5 17:35:03 2013
18 // Contact: http://ttcn.ericsson.se
19 //
20 ////////////////////////////////////////////////////////////////////////////////
21 // Generated from file(s):
22 // - XmlTest_union.xsd
23 // /* xml version = "1.0" */
24 // /* targetnamespace = "www.XmlTest.org/union" */
25 ////////////////////////////////////////////////////////////////////////////////
26 // Modification header(s):
27 //-----------------------------------------------------------------------------
28 // Modified by:
29 // Modification date:
30 // Description:
31 // Modification contact:
32 //------------------------------------------------------------------------------
33 ////////////////////////////////////////////////////////////////////////////////
34
35
36 module www_XmlTest_org_union_e {
37
38
39 import from XSD all;
40
41
42 /* This documentum tests based on
43 XML Schema Part 0: Primer Second Edition,
44 2.3.2 Union Types
45 Appendix B
46 XML Schema Part 2: Datatypes Second Edition */
47
48
49 type union MyUnion1
50 {
51 XSD.Float float_,
52 XSD.Boolean boolean_
53 }
54 with {
55 variant "useUnion";
56 variant (float_) "name as 'float'";
57 variant (boolean_) "name as 'boolean'";
58 //variant (boolean_) "text 'true' as '1'";
59 //variant (boolean_) "text 'false' as '0'";
60 };
61
62
63 type union MyUnion2
64 {
65 XSD.String string,
66 XSD.Boolean boolean_
67 }
68 with {
69 variant "useUnion";
70 variant (boolean_) "name as 'boolean'";
71 //variant (boolean_) "text 'true' as '1'";
72 //variant (boolean_) "text 'false' as '0'";
73 };
74
75
76 type union MyUnion3
77 {
78 XSD.String string,
79 XSD.Boolean boolean_,
80 XSD.Decimal decimal,
81 XSD.Time time,
82 XSD.Float float_,
83 XSD.Double double
84 }
85 with {
86 variant "useUnion";
87 variant (boolean_) "name as 'boolean'";
88 //variant (boolean_) "text 'true' as '1'";
89 //variant (boolean_) "text 'false' as '0'";
90 variant (float_) "name as 'float'";
91 };
92
93
94 type XSD.Boolean Result;
95 //with {
96 //variant "text 'true' as '1'";
97 //variant "text 'false' as '0'";
98 //};
99
100
101 type MyUnion1 MyUnion4
102 with {
103 variant "element";
104 };
105
106
107 }
108 with {
109 encode "XML";
110 variant "namespace as 'www.XmlTest.org/union' prefix 'ns2'";
111 variant "controlNamespace 'http://www.w3.org/2001/XMLSchema-instance' prefix 'xsi'";
112 }
This page took 0.034846 seconds and 5 git commands to generate.