Last sync 2016.04.01
[deliverable/titan.core.git] / regression_test / lazyEval / lazy_defs.ttcn
1 /******************************************************************************
2 * Copyright (c) 2000-2016 Ericsson Telecom AB
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Eclipse Public License v1.0
5 * which accompanies this distribution, and is available at
6 * http://www.eclipse.org/legal/epl-v10.html
7 *
8 * Contributors:
9 * Balasko, Jeno
10 *
11 ******************************************************************************/
12 module lazy_defs {
13
14 import from LazyASNTypes all;
15
16 type port My_PT message {
17 inout charstring;
18 } with { extension "internal"}
19
20 type component MyComp {
21 port My_PT PCO;
22 timer T1:=1.0;
23 var integer v_i:=0
24 var integer v_numberOfCalls:=0;
25 var charstring v_c:="";
26 var MyRec v_rec:= c_myRec;
27 var float v_f:=0.0;
28
29 }
30
31 type record of integer ROI;
32 type record of charstring ROC;
33
34 type record MyRec {
35 integer i,
36 ROI roi,
37 boolean b
38 }
39 //array
40 type boolean g[3];
41 type integer I3[3];
42 type float F3[3];
43 type charstring CS3[3];
44
45 //set
46 type set SET {
47 integer i,
48 ROI roi,
49 boolean b
50 }
51
52 type set of charstring SOCS
53 type enumerated EN { first, second, third }
54 type union UNION {
55 integer i,
56 ROI roi,
57 boolean b,
58 charstring cs
59 }
60
61 const charstring c_hi:= "Hi";
62 const boolean c_b := true;
63 const integer c_i := 1;
64 const float c_f := 1.0;
65 const bitstring c_bs := '1'B;
66 const octetstring c_os:= '55'O
67 const hexstring c_hs:='F'H
68 const charstring c_cs := "a"
69
70 const MyRec c_myRec := { 10, {11,12},true };
71 const ROC c_rocs := {"a"};
72 const CS3 c_cs3 := {"a","b","c"};
73 const SET c_set := { i := 10, roi := {11,12}, b:=true };
74 const SOCS c_socs := {"a","b","c","d"};
75 const EN c_enum := first
76 const UNION c_union := { cs := "myunion" }
77 const MyASNRecord c_asn1rec := { b:=true,i:=1,r:=1.0,bs:='1'B, os:='FF'O, cs:="a"}
78
79 template charstring t_hi:= "Hi";
80 template boolean t_b := true;
81 template integer t_i := 1;
82 template float t_f := 1.0;
83 template bitstring t_bs := '1'B;
84 template octetstring t_os:= '55'O
85 template hexstring t_hs:='F'H
86 template charstring t_cs := "a"
87
88 template MyRec t_myRec := { 10, {11,12},true };
89 template ROC t_rocs := {"a"};
90 template CS3 t_cs3 := {"a","b","c"};
91 template SET t_set := { i := 10, roi := {11,12}, b:=true };
92 template SOCS t_socs := {"a","b","c","d"};
93 template EN t_enum := first;
94 template UNION t_union := { cs := "myunion" }
95
96 }//module
This page took 0.033304 seconds and 5 git commands to generate.