Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
nemu3
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
nemu3
Commits
783c58e0
Commit
783c58e0
authored
Jul 29, 2010
by
Martín Ferrari
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
remove stuff that is not going to be used
parent
cd3bdb55
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
27 deletions
+3
-27
src/netns/interface.py
src/netns/interface.py
+3
-27
No files found.
src/netns/interface.py
View file @
783c58e0
...
...
@@ -289,33 +289,9 @@ class Link(ExternalInterface):
# Max 15 chars
return
"NETNSbr-%.4x%.3x"
%
(
os
.
getpid
(),
n
)
bandwidth
=
property
(
lambda
s
:
getattr
(
s
,
'_bandwidth'
))
delay
=
property
(
lambda
s
:
getattr
(
s
,
'_delay'
))
delay_jitter
=
property
(
lambda
s
:
getattr
(
s
,
'_delay_jitter'
))
delay_correlation
=
property
(
lambda
s
:
getattr
(
s
,
'_delay_correlation'
))
delay_distribution
=
property
(
lambda
s
:
getattr
(
s
,
'_delay_distribution'
))
loss
=
property
(
lambda
s
:
getattr
(
s
,
'_loss'
))
loss_correlation
=
property
(
lambda
s
:
getattr
(
s
,
'_loss_correlation'
))
dup
=
property
(
lambda
s
:
getattr
(
s
,
'_dup'
))
dup_correlation
=
property
(
lambda
s
:
getattr
(
s
,
'_dup_correlation'
))
def
__init__
(
self
,
bandwidth
=
None
,
delay
=
None
,
delay_jitter
=
None
,
delay_correlation
=
None
,
delay_distribution
=
None
,
loss
=
None
,
loss_correlation
=
None
,
dup
=
None
,
dup_correlation
=
None
,
corrupt
=
None
,
corrupt_correlation
=
None
):
self
.
_bandwidth
=
bandwidth
self
.
_delay
=
delay
self
.
_delay_jitter
=
delay_jitter
self
.
_delay_correlation
=
delay_correlation
self
.
_delay_distribution
=
delay_distribution
self
.
_loss
=
loss
self
.
_loss_correlation
=
loss_correlation
self
.
_dup
=
dup
self
.
_dup_correlation
=
dup_correlation
self
.
_corrupt
=
corrupt
self
.
_corrupt_correlation
=
corrupt_correlation
#, bandwidth = None, delay = None, delay_jitter = None, delay_correlation = None, delay_distribution = None, loss = None, loss_correlation = None, dup = None, dup_correlation = None, corrupt = None, corrupt_correlation = None
def
__init__
(
self
):
iface
=
netns
.
iproute
.
create_bridge
(
self
.
_gen_br_name
())
super
(
Link
,
self
).
__init__
(
iface
.
index
)
...
...
@@ -331,7 +307,7 @@ class Link(ExternalInterface):
def
__setattr__
(
self
,
name
,
value
):
if
name
[
0
]
==
'_'
:
# forbid anything that doesn't start with a _
super
(
ExternalInterface
,
self
).
__setattr__
(
name
,
value
)
super
(
Link
,
self
).
__setattr__
(
name
,
value
)
return
iface
=
netns
.
iproute
.
bridge
(
index
=
self
.
index
)
setattr
(
iface
,
name
,
value
)
...
...
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