Sync with 5.1.0
[deliverable/titan.core.git] / regression_test / BER / MyPort1.cc
1 ///////////////////////////////////////////////////////////////////////////////
2 // Copyright (c) 2000-2014 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 // This Test Port skeleton source file was generated by the
9 // TTCN-3 Compiler of the TTCN-3 Test Executor version 1.2.pl2
10 // for Matyas Forstner (tmpmfr@saussure) on Thu Oct 17 16:56:18 2002
11
12
13 // You may modify this file. Complete the body of empty functions and
14 // add your member functions here.
15
16 #include "MyPort1.hh"
17
18 #ifndef OLD_NAMES
19 namespace Regr {
20 #endif
21
22 MyPort1::MyPort1(const char *par_port_name)
23 : MyPort1_BASE(par_port_name)
24 {
25
26 }
27
28 MyPort1::~MyPort1()
29 {
30
31 }
32
33 void MyPort1::set_parameter(const char *parameter_name,
34 const char *parameter_value)
35 {
36
37 }
38
39 void MyPort1::Event_Handler(const fd_set *read_fds,
40 const fd_set *write_fds, const fd_set *error_fds,
41 double time_since_last_call)
42 {
43
44 }
45
46 void MyPort1::user_map(const char *system_port)
47 {
48
49 }
50
51 void MyPort1::user_unmap(const char *system_port)
52 {
53
54 }
55
56 void MyPort1::user_start()
57 {
58
59 }
60
61 void MyPort1::user_stop()
62 {
63
64 }
65
66 #ifndef OLD_NAMES
67
68 #define SEND_MACRO(module, type) \
69 void MyPort1::outgoing_send(const module::type& send_par) \
70 { \
71 TTCN_Buffer buf; \
72 send_par.encode(module::type##_descr_, buf, \
73 TTCN_EncDec::CT_BER, BER_ENCODE_DER); \
74 OCTETSTRING os; \
75 buf.get_string(os); \
76 incoming_message(os); \
77 }
78
79 #else
80
81 #define SEND_MACRO(module, type) \
82 void MyPort1::outgoing_send(const type& send_par) \
83 { \
84 TTCN_Buffer buf; \
85 send_par.encode(type##_descr_, buf, \
86 TTCN_EncDec::CT_BER, BER_ENCODE_DER); \
87 OCTETSTRING os; \
88 buf.get_string(os); \
89 incoming_message(os); \
90 }
91
92 #endif
93
94 SEND_MACRO(Regr1, T0)
95 SEND_MACRO(Regr1, T2)
96 SEND_MACRO(Regr1, T3)
97 SEND_MACRO(Regr1, T4)
98 SEND_MACRO(Regr1, T5)
99 SEND_MACRO(Regr1, T6)
100 SEND_MACRO(Regr1, T7)
101 SEND_MACRO(Regr1, T8)
102 SEND_MACRO(Regr2, T10)
103 SEND_MACRO(Regr2, T11)
104
105 #ifndef OLD_NAMES
106 } /* end of namespace */
107 #endif
This page took 0.031806 seconds and 5 git commands to generate.