author | Mathieu Lacage <mathieu.lacage@sophia.inria.fr> |
Mon, 27 Apr 2009 16:50:16 +0200 | |
changeset 4422 | f5ef533e56e4 |
parent 4204 | 1b2a20c85856 |
child 4449 | c11b6d768ab3 |
permissions | -rw-r--r-- |
3468
0bb5275704fc
Python: new pybindgen, rescan API definitions, new API definition files are more multi-line and hopefully easier to read
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3457
diff
changeset
|
1 |
from pybindgen import Module, FileCodeSink, param, retval, cppclass |
3408 | 2 |
|
3 |
||
4 |
import pybindgen.settings |
|
5 |
import warnings |
|
6 |
||
7 |
class ErrorHandler(pybindgen.settings.ErrorHandler): |
|
8 |
def handle_error(self, wrapper, exception, traceback_): |
|
9 |
warnings.warn("exception %r in wrapper %s" % (exception, wrapper)) |
|
10 |
return True |
|
11 |
pybindgen.settings.error_handler = ErrorHandler() |
|
12 |
||
13 |
||
14 |
import sys |
|
15 |
import ns3_module_core |
|
16 |
import ns3_module_simulator |
|
17 |
import ns3_module_mobility |
|
18 |
import ns3_module_common |
|
3972 | 19 |
import ns3_module_node |
3408 | 20 |
import ns3_module_contrib |
21 |
import ns3_module_point_to_point |
|
3574
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
22 |
import ns3_module_stats |
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
23 |
import ns3_module_tap_bridge |
3408 | 24 |
import ns3_module_internet_stack |
25 |
import ns3_module_wifi |
|
26 |
import ns3_module_csma |
|
3842
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
27 |
import ns3_module_emu |
3457 | 28 |
import ns3_module_bridge |
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
29 |
import ns3_module_onoff |
3408 | 30 |
import ns3_module_packet_sink |
3842
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
31 |
import ns3_module_v4ping |
3408 | 32 |
import ns3_module_global_routing |
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
33 |
import ns3_module_udp_echo |
3408 | 34 |
import ns3_module_olsr |
35 |
import ns3_module_helper |
|
36 |
||
37 |
def module_init(): |
|
38 |
root_module = Module('ns3', cpp_namespace='::ns3') |
|
39 |
return root_module |
|
40 |
||
41 |
def register_types(module): |
|
42 |
root_module = module.get_root() |
|
43 |
||
44 |
root_module.begin_section('ns3_module_core') |
|
45 |
ns3_module_core.register_types(module) |
|
46 |
||
47 |
try: |
|
48 |
import ns3_module_core__local |
|
49 |
except ImportError: |
|
50 |
pass |
|
51 |
else: |
|
52 |
ns3_module_core__local.register_types(module) |
|
53 |
||
54 |
root_module.end_section('ns3_module_core') |
|
55 |
root_module.begin_section('ns3_module_simulator') |
|
56 |
ns3_module_simulator.register_types(module) |
|
57 |
||
58 |
try: |
|
59 |
import ns3_module_simulator__local |
|
60 |
except ImportError: |
|
61 |
pass |
|
62 |
else: |
|
63 |
ns3_module_simulator__local.register_types(module) |
|
64 |
||
65 |
root_module.end_section('ns3_module_simulator') |
|
66 |
root_module.begin_section('ns3_module_mobility') |
|
67 |
ns3_module_mobility.register_types(module) |
|
68 |
||
69 |
try: |
|
70 |
import ns3_module_mobility__local |
|
71 |
except ImportError: |
|
72 |
pass |
|
73 |
else: |
|
74 |
ns3_module_mobility__local.register_types(module) |
|
75 |
||
76 |
root_module.end_section('ns3_module_mobility') |
|
77 |
root_module.begin_section('ns3_module_common') |
|
78 |
ns3_module_common.register_types(module) |
|
79 |
||
80 |
try: |
|
81 |
import ns3_module_common__local |
|
82 |
except ImportError: |
|
83 |
pass |
|
84 |
else: |
|
85 |
ns3_module_common__local.register_types(module) |
|
86 |
||
87 |
root_module.end_section('ns3_module_common') |
|
3972 | 88 |
root_module.begin_section('ns3_module_node') |
89 |
ns3_module_node.register_types(module) |
|
90 |
||
91 |
try: |
|
92 |
import ns3_module_node__local |
|
93 |
except ImportError: |
|
94 |
pass |
|
95 |
else: |
|
96 |
ns3_module_node__local.register_types(module) |
|
97 |
||
98 |
root_module.end_section('ns3_module_node') |
|
3408 | 99 |
root_module.begin_section('ns3_module_contrib') |
100 |
ns3_module_contrib.register_types(module) |
|
101 |
||
102 |
try: |
|
103 |
import ns3_module_contrib__local |
|
104 |
except ImportError: |
|
105 |
pass |
|
106 |
else: |
|
107 |
ns3_module_contrib__local.register_types(module) |
|
108 |
||
109 |
root_module.end_section('ns3_module_contrib') |
|
110 |
root_module.begin_section('ns3_module_point_to_point') |
|
111 |
ns3_module_point_to_point.register_types(module) |
|
112 |
||
113 |
try: |
|
114 |
import ns3_module_point_to_point__local |
|
115 |
except ImportError: |
|
116 |
pass |
|
117 |
else: |
|
118 |
ns3_module_point_to_point__local.register_types(module) |
|
119 |
||
120 |
root_module.end_section('ns3_module_point_to_point') |
|
3574
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
121 |
root_module.begin_section('ns3_module_stats') |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
122 |
ns3_module_stats.register_types(module) |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
123 |
|
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
124 |
try: |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
125 |
import ns3_module_stats__local |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
126 |
except ImportError: |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
127 |
pass |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
128 |
else: |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
129 |
ns3_module_stats__local.register_types(module) |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
130 |
|
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
131 |
root_module.end_section('ns3_module_stats') |
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
132 |
root_module.begin_section('ns3_module_tap_bridge') |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
133 |
ns3_module_tap_bridge.register_types(module) |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
134 |
|
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
135 |
try: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
136 |
import ns3_module_tap_bridge__local |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
137 |
except ImportError: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
138 |
pass |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
139 |
else: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
140 |
ns3_module_tap_bridge__local.register_types(module) |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
141 |
|
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
142 |
root_module.end_section('ns3_module_tap_bridge') |
3408 | 143 |
root_module.begin_section('ns3_module_internet_stack') |
144 |
ns3_module_internet_stack.register_types(module) |
|
145 |
||
146 |
try: |
|
147 |
import ns3_module_internet_stack__local |
|
148 |
except ImportError: |
|
149 |
pass |
|
150 |
else: |
|
151 |
ns3_module_internet_stack__local.register_types(module) |
|
152 |
||
153 |
root_module.end_section('ns3_module_internet_stack') |
|
154 |
root_module.begin_section('ns3_module_wifi') |
|
155 |
ns3_module_wifi.register_types(module) |
|
156 |
||
157 |
try: |
|
158 |
import ns3_module_wifi__local |
|
159 |
except ImportError: |
|
160 |
pass |
|
161 |
else: |
|
162 |
ns3_module_wifi__local.register_types(module) |
|
163 |
||
164 |
root_module.end_section('ns3_module_wifi') |
|
165 |
root_module.begin_section('ns3_module_csma') |
|
166 |
ns3_module_csma.register_types(module) |
|
167 |
||
168 |
try: |
|
169 |
import ns3_module_csma__local |
|
170 |
except ImportError: |
|
171 |
pass |
|
172 |
else: |
|
173 |
ns3_module_csma__local.register_types(module) |
|
174 |
||
175 |
root_module.end_section('ns3_module_csma') |
|
3842
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
176 |
root_module.begin_section('ns3_module_emu') |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
177 |
ns3_module_emu.register_types(module) |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
178 |
|
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
179 |
try: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
180 |
import ns3_module_emu__local |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
181 |
except ImportError: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
182 |
pass |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
183 |
else: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
184 |
ns3_module_emu__local.register_types(module) |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
185 |
|
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
186 |
root_module.end_section('ns3_module_emu') |
3457 | 187 |
root_module.begin_section('ns3_module_bridge') |
188 |
ns3_module_bridge.register_types(module) |
|
189 |
||
190 |
try: |
|
191 |
import ns3_module_bridge__local |
|
192 |
except ImportError: |
|
193 |
pass |
|
194 |
else: |
|
195 |
ns3_module_bridge__local.register_types(module) |
|
196 |
||
197 |
root_module.end_section('ns3_module_bridge') |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
198 |
root_module.begin_section('ns3_module_onoff') |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
199 |
ns3_module_onoff.register_types(module) |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
200 |
|
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
201 |
try: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
202 |
import ns3_module_onoff__local |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
203 |
except ImportError: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
204 |
pass |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
205 |
else: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
206 |
ns3_module_onoff__local.register_types(module) |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
207 |
|
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
208 |
root_module.end_section('ns3_module_onoff') |
3408 | 209 |
root_module.begin_section('ns3_module_packet_sink') |
210 |
ns3_module_packet_sink.register_types(module) |
|
211 |
||
212 |
try: |
|
213 |
import ns3_module_packet_sink__local |
|
214 |
except ImportError: |
|
215 |
pass |
|
216 |
else: |
|
217 |
ns3_module_packet_sink__local.register_types(module) |
|
218 |
||
219 |
root_module.end_section('ns3_module_packet_sink') |
|
3842
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
220 |
root_module.begin_section('ns3_module_v4ping') |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
221 |
ns3_module_v4ping.register_types(module) |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
222 |
|
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
223 |
try: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
224 |
import ns3_module_v4ping__local |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
225 |
except ImportError: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
226 |
pass |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
227 |
else: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
228 |
ns3_module_v4ping__local.register_types(module) |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
229 |
|
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
230 |
root_module.end_section('ns3_module_v4ping') |
3408 | 231 |
root_module.begin_section('ns3_module_global_routing') |
232 |
ns3_module_global_routing.register_types(module) |
|
233 |
||
234 |
try: |
|
235 |
import ns3_module_global_routing__local |
|
236 |
except ImportError: |
|
237 |
pass |
|
238 |
else: |
|
239 |
ns3_module_global_routing__local.register_types(module) |
|
240 |
||
241 |
root_module.end_section('ns3_module_global_routing') |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
242 |
root_module.begin_section('ns3_module_udp_echo') |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
243 |
ns3_module_udp_echo.register_types(module) |
3408 | 244 |
|
245 |
try: |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
246 |
import ns3_module_udp_echo__local |
3408 | 247 |
except ImportError: |
248 |
pass |
|
249 |
else: |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
250 |
ns3_module_udp_echo__local.register_types(module) |
3408 | 251 |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
252 |
root_module.end_section('ns3_module_udp_echo') |
3408 | 253 |
root_module.begin_section('ns3_module_olsr') |
254 |
ns3_module_olsr.register_types(module) |
|
255 |
||
256 |
try: |
|
257 |
import ns3_module_olsr__local |
|
258 |
except ImportError: |
|
259 |
pass |
|
260 |
else: |
|
261 |
ns3_module_olsr__local.register_types(module) |
|
262 |
||
263 |
root_module.end_section('ns3_module_olsr') |
|
264 |
root_module.begin_section('ns3_module_helper') |
|
265 |
ns3_module_helper.register_types(module) |
|
266 |
||
267 |
try: |
|
268 |
import ns3_module_helper__local |
|
269 |
except ImportError: |
|
270 |
pass |
|
271 |
else: |
|
272 |
ns3_module_helper__local.register_types(module) |
|
273 |
||
274 |
root_module.end_section('ns3_module_helper') |
|
3731
317f9dbccc2b
New pybindgen and new API scanning, brings support for comparison operators and + - * / numeric operators.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3574
diff
changeset
|
275 |
module.add_container('std::vector< unsigned int >', 'unsigned int', container_type='vector') |
317f9dbccc2b
New pybindgen and new API scanning, brings support for comparison operators and + - * / numeric operators.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3574
diff
changeset
|
276 |
module.add_container('std::list< unsigned int >', 'unsigned int', container_type='list') |
4422
f5ef533e56e4
rescan python bindings
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
4204
diff
changeset
|
277 |
module.add_container('std::list< std::pair< ns3::Ptr< ns3::Packet >, ns3::AmsduSubframeHeader > >', 'std::pair< ns3::Ptr< ns3::Packet >, ns3::AmsduSubframeHeader >', container_type='list') |
3408 | 278 |
|
3855
7fdcbeea6c4f
Python: require new pybindgen and re-scan API to make the list of free functions and namespaces sorted.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3842
diff
changeset
|
279 |
## Register a nested module for the namespace Config |
3408 | 280 |
|
3855
7fdcbeea6c4f
Python: require new pybindgen and re-scan API to make the list of free functions and namespaces sorted.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3842
diff
changeset
|
281 |
nested_module = module.add_cpp_namespace('Config') |
7fdcbeea6c4f
Python: require new pybindgen and re-scan API to make the list of free functions and namespaces sorted.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3842
diff
changeset
|
282 |
register_types_ns3_Config(nested_module) |
3408 | 283 |
|
284 |
||
285 |
## Register a nested module for the namespace TimeStepPrecision |
|
286 |
||
287 |
nested_module = module.add_cpp_namespace('TimeStepPrecision') |
|
288 |
register_types_ns3_TimeStepPrecision(nested_module) |
|
289 |
||
290 |
||
3855
7fdcbeea6c4f
Python: require new pybindgen and re-scan API to make the list of free functions and namespaces sorted.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3842
diff
changeset
|
291 |
## Register a nested module for the namespace internal |
3408 | 292 |
|
3855
7fdcbeea6c4f
Python: require new pybindgen and re-scan API to make the list of free functions and namespaces sorted.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3842
diff
changeset
|
293 |
nested_module = module.add_cpp_namespace('internal') |
7fdcbeea6c4f
Python: require new pybindgen and re-scan API to make the list of free functions and namespaces sorted.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3842
diff
changeset
|
294 |
register_types_ns3_internal(nested_module) |
3408 | 295 |
|
296 |
||
297 |
## Register a nested module for the namespace olsr |
|
298 |
||
299 |
nested_module = module.add_cpp_namespace('olsr') |
|
300 |
register_types_ns3_olsr(nested_module) |
|
301 |
||
302 |
||
3855
7fdcbeea6c4f
Python: require new pybindgen and re-scan API to make the list of free functions and namespaces sorted.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3842
diff
changeset
|
303 |
def register_types_ns3_Config(module): |
3408 | 304 |
root_module = module.get_root() |
305 |
||
3855
7fdcbeea6c4f
Python: require new pybindgen and re-scan API to make the list of free functions and namespaces sorted.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3842
diff
changeset
|
306 |
module.add_container('std::vector< std::string >', 'std::string', container_type='vector') |
3408 | 307 |
|
308 |
def register_types_ns3_TimeStepPrecision(module): |
|
309 |
root_module = module.get_root() |
|
310 |
||
311 |
||
3855
7fdcbeea6c4f
Python: require new pybindgen and re-scan API to make the list of free functions and namespaces sorted.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3842
diff
changeset
|
312 |
def register_types_ns3_internal(module): |
3408 | 313 |
root_module = module.get_root() |
314 |
||
315 |
||
316 |
def register_types_ns3_olsr(module): |
|
317 |
root_module = module.get_root() |
|
318 |
||
319 |
||
320 |
def register_methods(root_module): |
|
321 |
root_module.begin_section('ns3_module_core') |
|
322 |
ns3_module_core.register_methods(root_module) |
|
323 |
||
324 |
try: |
|
325 |
import ns3_module_core__local |
|
326 |
except ImportError: |
|
327 |
pass |
|
328 |
else: |
|
329 |
ns3_module_core__local.register_methods(root_module) |
|
330 |
||
331 |
root_module.end_section('ns3_module_core') |
|
332 |
root_module.begin_section('ns3_module_simulator') |
|
333 |
ns3_module_simulator.register_methods(root_module) |
|
334 |
||
335 |
try: |
|
336 |
import ns3_module_simulator__local |
|
337 |
except ImportError: |
|
338 |
pass |
|
339 |
else: |
|
340 |
ns3_module_simulator__local.register_methods(root_module) |
|
341 |
||
342 |
root_module.end_section('ns3_module_simulator') |
|
343 |
root_module.begin_section('ns3_module_mobility') |
|
344 |
ns3_module_mobility.register_methods(root_module) |
|
345 |
||
346 |
try: |
|
347 |
import ns3_module_mobility__local |
|
348 |
except ImportError: |
|
349 |
pass |
|
350 |
else: |
|
351 |
ns3_module_mobility__local.register_methods(root_module) |
|
352 |
||
353 |
root_module.end_section('ns3_module_mobility') |
|
354 |
root_module.begin_section('ns3_module_common') |
|
355 |
ns3_module_common.register_methods(root_module) |
|
356 |
||
357 |
try: |
|
358 |
import ns3_module_common__local |
|
359 |
except ImportError: |
|
360 |
pass |
|
361 |
else: |
|
362 |
ns3_module_common__local.register_methods(root_module) |
|
363 |
||
364 |
root_module.end_section('ns3_module_common') |
|
3972 | 365 |
root_module.begin_section('ns3_module_node') |
366 |
ns3_module_node.register_methods(root_module) |
|
367 |
||
368 |
try: |
|
369 |
import ns3_module_node__local |
|
370 |
except ImportError: |
|
371 |
pass |
|
372 |
else: |
|
373 |
ns3_module_node__local.register_methods(root_module) |
|
374 |
||
375 |
root_module.end_section('ns3_module_node') |
|
3408 | 376 |
root_module.begin_section('ns3_module_contrib') |
377 |
ns3_module_contrib.register_methods(root_module) |
|
378 |
||
379 |
try: |
|
380 |
import ns3_module_contrib__local |
|
381 |
except ImportError: |
|
382 |
pass |
|
383 |
else: |
|
384 |
ns3_module_contrib__local.register_methods(root_module) |
|
385 |
||
386 |
root_module.end_section('ns3_module_contrib') |
|
387 |
root_module.begin_section('ns3_module_point_to_point') |
|
388 |
ns3_module_point_to_point.register_methods(root_module) |
|
389 |
||
390 |
try: |
|
391 |
import ns3_module_point_to_point__local |
|
392 |
except ImportError: |
|
393 |
pass |
|
394 |
else: |
|
395 |
ns3_module_point_to_point__local.register_methods(root_module) |
|
396 |
||
397 |
root_module.end_section('ns3_module_point_to_point') |
|
3574
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
398 |
root_module.begin_section('ns3_module_stats') |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
399 |
ns3_module_stats.register_methods(root_module) |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
400 |
|
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
401 |
try: |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
402 |
import ns3_module_stats__local |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
403 |
except ImportError: |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
404 |
pass |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
405 |
else: |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
406 |
ns3_module_stats__local.register_methods(root_module) |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
407 |
|
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
408 |
root_module.end_section('ns3_module_stats') |
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
409 |
root_module.begin_section('ns3_module_tap_bridge') |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
410 |
ns3_module_tap_bridge.register_methods(root_module) |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
411 |
|
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
412 |
try: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
413 |
import ns3_module_tap_bridge__local |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
414 |
except ImportError: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
415 |
pass |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
416 |
else: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
417 |
ns3_module_tap_bridge__local.register_methods(root_module) |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
418 |
|
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
419 |
root_module.end_section('ns3_module_tap_bridge') |
3408 | 420 |
root_module.begin_section('ns3_module_internet_stack') |
421 |
ns3_module_internet_stack.register_methods(root_module) |
|
422 |
||
423 |
try: |
|
424 |
import ns3_module_internet_stack__local |
|
425 |
except ImportError: |
|
426 |
pass |
|
427 |
else: |
|
428 |
ns3_module_internet_stack__local.register_methods(root_module) |
|
429 |
||
430 |
root_module.end_section('ns3_module_internet_stack') |
|
431 |
root_module.begin_section('ns3_module_wifi') |
|
432 |
ns3_module_wifi.register_methods(root_module) |
|
433 |
||
434 |
try: |
|
435 |
import ns3_module_wifi__local |
|
436 |
except ImportError: |
|
437 |
pass |
|
438 |
else: |
|
439 |
ns3_module_wifi__local.register_methods(root_module) |
|
440 |
||
441 |
root_module.end_section('ns3_module_wifi') |
|
442 |
root_module.begin_section('ns3_module_csma') |
|
443 |
ns3_module_csma.register_methods(root_module) |
|
444 |
||
445 |
try: |
|
446 |
import ns3_module_csma__local |
|
447 |
except ImportError: |
|
448 |
pass |
|
449 |
else: |
|
450 |
ns3_module_csma__local.register_methods(root_module) |
|
451 |
||
452 |
root_module.end_section('ns3_module_csma') |
|
3842
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
453 |
root_module.begin_section('ns3_module_emu') |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
454 |
ns3_module_emu.register_methods(root_module) |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
455 |
|
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
456 |
try: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
457 |
import ns3_module_emu__local |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
458 |
except ImportError: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
459 |
pass |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
460 |
else: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
461 |
ns3_module_emu__local.register_methods(root_module) |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
462 |
|
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
463 |
root_module.end_section('ns3_module_emu') |
3457 | 464 |
root_module.begin_section('ns3_module_bridge') |
465 |
ns3_module_bridge.register_methods(root_module) |
|
466 |
||
467 |
try: |
|
468 |
import ns3_module_bridge__local |
|
469 |
except ImportError: |
|
470 |
pass |
|
471 |
else: |
|
472 |
ns3_module_bridge__local.register_methods(root_module) |
|
473 |
||
474 |
root_module.end_section('ns3_module_bridge') |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
475 |
root_module.begin_section('ns3_module_onoff') |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
476 |
ns3_module_onoff.register_methods(root_module) |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
477 |
|
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
478 |
try: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
479 |
import ns3_module_onoff__local |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
480 |
except ImportError: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
481 |
pass |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
482 |
else: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
483 |
ns3_module_onoff__local.register_methods(root_module) |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
484 |
|
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
485 |
root_module.end_section('ns3_module_onoff') |
3408 | 486 |
root_module.begin_section('ns3_module_packet_sink') |
487 |
ns3_module_packet_sink.register_methods(root_module) |
|
488 |
||
489 |
try: |
|
490 |
import ns3_module_packet_sink__local |
|
491 |
except ImportError: |
|
492 |
pass |
|
493 |
else: |
|
494 |
ns3_module_packet_sink__local.register_methods(root_module) |
|
495 |
||
496 |
root_module.end_section('ns3_module_packet_sink') |
|
3842
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
497 |
root_module.begin_section('ns3_module_v4ping') |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
498 |
ns3_module_v4ping.register_methods(root_module) |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
499 |
|
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
500 |
try: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
501 |
import ns3_module_v4ping__local |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
502 |
except ImportError: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
503 |
pass |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
504 |
else: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
505 |
ns3_module_v4ping__local.register_methods(root_module) |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
506 |
|
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
507 |
root_module.end_section('ns3_module_v4ping') |
3408 | 508 |
root_module.begin_section('ns3_module_global_routing') |
509 |
ns3_module_global_routing.register_methods(root_module) |
|
510 |
||
511 |
try: |
|
512 |
import ns3_module_global_routing__local |
|
513 |
except ImportError: |
|
514 |
pass |
|
515 |
else: |
|
516 |
ns3_module_global_routing__local.register_methods(root_module) |
|
517 |
||
518 |
root_module.end_section('ns3_module_global_routing') |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
519 |
root_module.begin_section('ns3_module_udp_echo') |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
520 |
ns3_module_udp_echo.register_methods(root_module) |
3408 | 521 |
|
522 |
try: |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
523 |
import ns3_module_udp_echo__local |
3408 | 524 |
except ImportError: |
525 |
pass |
|
526 |
else: |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
527 |
ns3_module_udp_echo__local.register_methods(root_module) |
3408 | 528 |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
529 |
root_module.end_section('ns3_module_udp_echo') |
3408 | 530 |
root_module.begin_section('ns3_module_olsr') |
531 |
ns3_module_olsr.register_methods(root_module) |
|
532 |
||
533 |
try: |
|
534 |
import ns3_module_olsr__local |
|
535 |
except ImportError: |
|
536 |
pass |
|
537 |
else: |
|
538 |
ns3_module_olsr__local.register_methods(root_module) |
|
539 |
||
540 |
root_module.end_section('ns3_module_olsr') |
|
541 |
root_module.begin_section('ns3_module_helper') |
|
542 |
ns3_module_helper.register_methods(root_module) |
|
543 |
||
544 |
try: |
|
545 |
import ns3_module_helper__local |
|
546 |
except ImportError: |
|
547 |
pass |
|
548 |
else: |
|
549 |
ns3_module_helper__local.register_methods(root_module) |
|
550 |
||
551 |
root_module.end_section('ns3_module_helper') |
|
552 |
return |
|
553 |
||
554 |
def register_functions(root_module): |
|
555 |
module = root_module |
|
556 |
root_module.begin_section('ns3_module_core') |
|
557 |
ns3_module_core.register_functions(root_module) |
|
558 |
||
559 |
try: |
|
560 |
import ns3_module_core__local |
|
561 |
except ImportError: |
|
562 |
pass |
|
563 |
else: |
|
564 |
ns3_module_core__local.register_functions(root_module) |
|
565 |
||
566 |
root_module.end_section('ns3_module_core') |
|
567 |
root_module.begin_section('ns3_module_simulator') |
|
568 |
ns3_module_simulator.register_functions(root_module) |
|
569 |
||
570 |
try: |
|
571 |
import ns3_module_simulator__local |
|
572 |
except ImportError: |
|
573 |
pass |
|
574 |
else: |
|
575 |
ns3_module_simulator__local.register_functions(root_module) |
|
576 |
||
577 |
root_module.end_section('ns3_module_simulator') |
|
578 |
root_module.begin_section('ns3_module_mobility') |
|
579 |
ns3_module_mobility.register_functions(root_module) |
|
580 |
||
581 |
try: |
|
582 |
import ns3_module_mobility__local |
|
583 |
except ImportError: |
|
584 |
pass |
|
585 |
else: |
|
586 |
ns3_module_mobility__local.register_functions(root_module) |
|
587 |
||
588 |
root_module.end_section('ns3_module_mobility') |
|
589 |
root_module.begin_section('ns3_module_common') |
|
590 |
ns3_module_common.register_functions(root_module) |
|
591 |
||
592 |
try: |
|
593 |
import ns3_module_common__local |
|
594 |
except ImportError: |
|
595 |
pass |
|
596 |
else: |
|
597 |
ns3_module_common__local.register_functions(root_module) |
|
598 |
||
599 |
root_module.end_section('ns3_module_common') |
|
3972 | 600 |
root_module.begin_section('ns3_module_node') |
601 |
ns3_module_node.register_functions(root_module) |
|
602 |
||
603 |
try: |
|
604 |
import ns3_module_node__local |
|
605 |
except ImportError: |
|
606 |
pass |
|
607 |
else: |
|
608 |
ns3_module_node__local.register_functions(root_module) |
|
609 |
||
610 |
root_module.end_section('ns3_module_node') |
|
3408 | 611 |
root_module.begin_section('ns3_module_contrib') |
612 |
ns3_module_contrib.register_functions(root_module) |
|
613 |
||
614 |
try: |
|
615 |
import ns3_module_contrib__local |
|
616 |
except ImportError: |
|
617 |
pass |
|
618 |
else: |
|
619 |
ns3_module_contrib__local.register_functions(root_module) |
|
620 |
||
621 |
root_module.end_section('ns3_module_contrib') |
|
622 |
root_module.begin_section('ns3_module_point_to_point') |
|
623 |
ns3_module_point_to_point.register_functions(root_module) |
|
624 |
||
625 |
try: |
|
626 |
import ns3_module_point_to_point__local |
|
627 |
except ImportError: |
|
628 |
pass |
|
629 |
else: |
|
630 |
ns3_module_point_to_point__local.register_functions(root_module) |
|
631 |
||
632 |
root_module.end_section('ns3_module_point_to_point') |
|
3574
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
633 |
root_module.begin_section('ns3_module_stats') |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
634 |
ns3_module_stats.register_functions(root_module) |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
635 |
|
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
636 |
try: |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
637 |
import ns3_module_stats__local |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
638 |
except ImportError: |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
639 |
pass |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
640 |
else: |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
641 |
ns3_module_stats__local.register_functions(root_module) |
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
642 |
|
b6804efbe16b
New pybindgen and API rescan. Extensive API description files changes because pybindgen now handles consts differently.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3567
diff
changeset
|
643 |
root_module.end_section('ns3_module_stats') |
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
644 |
root_module.begin_section('ns3_module_tap_bridge') |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
645 |
ns3_module_tap_bridge.register_functions(root_module) |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
646 |
|
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
647 |
try: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
648 |
import ns3_module_tap_bridge__local |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
649 |
except ImportError: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
650 |
pass |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
651 |
else: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
652 |
ns3_module_tap_bridge__local.register_functions(root_module) |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
653 |
|
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
654 |
root_module.end_section('ns3_module_tap_bridge') |
3408 | 655 |
root_module.begin_section('ns3_module_internet_stack') |
656 |
ns3_module_internet_stack.register_functions(root_module) |
|
657 |
||
658 |
try: |
|
659 |
import ns3_module_internet_stack__local |
|
660 |
except ImportError: |
|
661 |
pass |
|
662 |
else: |
|
663 |
ns3_module_internet_stack__local.register_functions(root_module) |
|
664 |
||
665 |
root_module.end_section('ns3_module_internet_stack') |
|
666 |
root_module.begin_section('ns3_module_wifi') |
|
667 |
ns3_module_wifi.register_functions(root_module) |
|
668 |
||
669 |
try: |
|
670 |
import ns3_module_wifi__local |
|
671 |
except ImportError: |
|
672 |
pass |
|
673 |
else: |
|
674 |
ns3_module_wifi__local.register_functions(root_module) |
|
675 |
||
676 |
root_module.end_section('ns3_module_wifi') |
|
677 |
root_module.begin_section('ns3_module_csma') |
|
678 |
ns3_module_csma.register_functions(root_module) |
|
679 |
||
680 |
try: |
|
681 |
import ns3_module_csma__local |
|
682 |
except ImportError: |
|
683 |
pass |
|
684 |
else: |
|
685 |
ns3_module_csma__local.register_functions(root_module) |
|
686 |
||
687 |
root_module.end_section('ns3_module_csma') |
|
3842
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
688 |
root_module.begin_section('ns3_module_emu') |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
689 |
ns3_module_emu.register_functions(root_module) |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
690 |
|
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
691 |
try: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
692 |
import ns3_module_emu__local |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
693 |
except ImportError: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
694 |
pass |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
695 |
else: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
696 |
ns3_module_emu__local.register_functions(root_module) |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
697 |
|
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
698 |
root_module.end_section('ns3_module_emu') |
3457 | 699 |
root_module.begin_section('ns3_module_bridge') |
700 |
ns3_module_bridge.register_functions(root_module) |
|
701 |
||
702 |
try: |
|
703 |
import ns3_module_bridge__local |
|
704 |
except ImportError: |
|
705 |
pass |
|
706 |
else: |
|
707 |
ns3_module_bridge__local.register_functions(root_module) |
|
708 |
||
709 |
root_module.end_section('ns3_module_bridge') |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
710 |
root_module.begin_section('ns3_module_onoff') |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
711 |
ns3_module_onoff.register_functions(root_module) |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
712 |
|
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
713 |
try: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
714 |
import ns3_module_onoff__local |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
715 |
except ImportError: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
716 |
pass |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
717 |
else: |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
718 |
ns3_module_onoff__local.register_functions(root_module) |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
719 |
|
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
720 |
root_module.end_section('ns3_module_onoff') |
3408 | 721 |
root_module.begin_section('ns3_module_packet_sink') |
722 |
ns3_module_packet_sink.register_functions(root_module) |
|
723 |
||
724 |
try: |
|
725 |
import ns3_module_packet_sink__local |
|
726 |
except ImportError: |
|
727 |
pass |
|
728 |
else: |
|
729 |
ns3_module_packet_sink__local.register_functions(root_module) |
|
730 |
||
731 |
root_module.end_section('ns3_module_packet_sink') |
|
3842
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
732 |
root_module.begin_section('ns3_module_v4ping') |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
733 |
ns3_module_v4ping.register_functions(root_module) |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
734 |
|
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
735 |
try: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
736 |
import ns3_module_v4ping__local |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
737 |
except ImportError: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
738 |
pass |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
739 |
else: |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
740 |
ns3_module_v4ping__local.register_functions(root_module) |
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
741 |
|
545ddf9398ed
apply patch for bug 294 (GetMulticastAddr) + emu device update + rescan
vincent@clarinet.u-strasbg.fr
parents:
3816
diff
changeset
|
742 |
root_module.end_section('ns3_module_v4ping') |
3408 | 743 |
root_module.begin_section('ns3_module_global_routing') |
744 |
ns3_module_global_routing.register_functions(root_module) |
|
745 |
||
746 |
try: |
|
747 |
import ns3_module_global_routing__local |
|
748 |
except ImportError: |
|
749 |
pass |
|
750 |
else: |
|
751 |
ns3_module_global_routing__local.register_functions(root_module) |
|
752 |
||
753 |
root_module.end_section('ns3_module_global_routing') |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
754 |
root_module.begin_section('ns3_module_udp_echo') |
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
755 |
ns3_module_udp_echo.register_functions(root_module) |
3408 | 756 |
|
757 |
try: |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
758 |
import ns3_module_udp_echo__local |
3408 | 759 |
except ImportError: |
760 |
pass |
|
761 |
else: |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
762 |
ns3_module_udp_echo__local.register_functions(root_module) |
3408 | 763 |
|
4204
1b2a20c85856
Rescan python bindings.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3972
diff
changeset
|
764 |
root_module.end_section('ns3_module_udp_echo') |
3408 | 765 |
root_module.begin_section('ns3_module_olsr') |
766 |
ns3_module_olsr.register_functions(root_module) |
|
767 |
||
768 |
try: |
|
769 |
import ns3_module_olsr__local |
|
770 |
except ImportError: |
|
771 |
pass |
|
772 |
else: |
|
773 |
ns3_module_olsr__local.register_functions(root_module) |
|
774 |
||
775 |
root_module.end_section('ns3_module_olsr') |
|
776 |
root_module.begin_section('ns3_module_helper') |
|
777 |
ns3_module_helper.register_functions(root_module) |
|
778 |
||
779 |
try: |
|
780 |
import ns3_module_helper__local |
|
781 |
except ImportError: |
|
782 |
pass |
|
783 |
else: |
|
784 |
ns3_module_helper__local.register_functions(root_module) |
|
785 |
||
786 |
root_module.end_section('ns3_module_helper') |
|
3855
7fdcbeea6c4f
Python: require new pybindgen and re-scan API to make the list of free functions and namespaces sorted.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3842
diff
changeset
|
787 |
register_functions_ns3_Config(module.get_submodule('Config'), root_module) |
3408 | 788 |
register_functions_ns3_TimeStepPrecision(module.get_submodule('TimeStepPrecision'), root_module) |
3855
7fdcbeea6c4f
Python: require new pybindgen and re-scan API to make the list of free functions and namespaces sorted.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3842
diff
changeset
|
789 |
register_functions_ns3_internal(module.get_submodule('internal'), root_module) |
3408 | 790 |
register_functions_ns3_olsr(module.get_submodule('olsr'), root_module) |
791 |
return |
|
792 |
||
3855
7fdcbeea6c4f
Python: require new pybindgen and re-scan API to make the list of free functions and namespaces sorted.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3842
diff
changeset
|
793 |
def register_functions_ns3_Config(module, root_module): |
3408 | 794 |
return |
795 |
||
796 |
def register_functions_ns3_TimeStepPrecision(module, root_module): |
|
797 |
return |
|
798 |
||
3855
7fdcbeea6c4f
Python: require new pybindgen and re-scan API to make the list of free functions and namespaces sorted.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents:
3842
diff
changeset
|
799 |
def register_functions_ns3_internal(module, root_module): |
3408 | 800 |
return |
801 |
||
802 |
def register_functions_ns3_olsr(module, root_module): |
|
803 |
return |
|
804 |
||
805 |
def main(): |
|
806 |
out = FileCodeSink(sys.stdout) |
|
807 |
root_module = module_init() |
|
808 |
register_types(root_module) |
|
809 |
register_methods(root_module) |
|
810 |
register_functions(root_module) |
|
811 |
root_module.generate(out) |
|
812 |
||
813 |
if __name__ == '__main__': |
|
814 |
main() |
|
815 |