Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ycai
simbricks
Commits
33eac66e
Commit
33eac66e
authored
Jan 15, 2024
by
Antoine Kaufmann
Committed by
Antoine Kaufmann
May 08, 2024
Browse files
experiments: add wait flag to network simulators as well
Useful for running ns-3 only simulations.
parent
fba7164d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
experiments/simbricks/orchestration/simulators.py
experiments/simbricks/orchestration/simulators.py
+4
-0
No files found.
experiments/simbricks/orchestration/simulators.py
View file @
33eac66e
...
@@ -195,6 +195,7 @@ class NetSim(Simulator):
...
@@ -195,6 +195,7 @@ class NetSim(Simulator):
self
.
hosts_direct
:
list
[
HostSim
]
=
[]
self
.
hosts_direct
:
list
[
HostSim
]
=
[]
self
.
net_listen
:
list
[
NetSim
]
=
[]
self
.
net_listen
:
list
[
NetSim
]
=
[]
self
.
net_connect
:
list
[
NetSim
]
=
[]
self
.
net_connect
:
list
[
NetSim
]
=
[]
self
.
wait
=
False
def
full_name
(
self
)
->
str
:
def
full_name
(
self
)
->
str
:
return
'net.'
+
self
.
name
return
'net.'
+
self
.
name
...
@@ -229,6 +230,9 @@ class NetSim(Simulator):
...
@@ -229,6 +230,9 @@ class NetSim(Simulator):
def
sockets_wait
(
self
,
env
:
ExpEnv
)
->
tp
.
List
[
str
]:
def
sockets_wait
(
self
,
env
:
ExpEnv
)
->
tp
.
List
[
str
]:
return
[
s
for
(
_
,
s
)
in
self
.
listen_sockets
(
env
)]
return
[
s
for
(
_
,
s
)
in
self
.
listen_sockets
(
env
)]
def
wait_terminate
(
self
)
->
Bool
:
return
self
.
wait
# FIXME: Class hierarchy is broken here as an ugly hack
# FIXME: Class hierarchy is broken here as an ugly hack
class
MemDevSim
(
NICSim
):
class
MemDevSim
(
NICSim
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment