Move init() into Mininet() and remove calls (since called automatically.)
Note: we should probably rename it "setup()" to avoid confusion.
This commit is contained in:
@@ -19,7 +19,7 @@ import time
|
||||
from mininet.clean import cleanup
|
||||
from mininet.cli import CLI
|
||||
from mininet.log import lg, LEVELS, info, warn
|
||||
from mininet.net import Mininet, init
|
||||
from mininet.net import Mininet
|
||||
from mininet.node import Host, CPULimitedHost, Controller, OVSController, NOX
|
||||
from mininet.node import RemoteController, UserSwitch, OVSKernelSwitch
|
||||
from mininet.link import Intf, TCIntf
|
||||
@@ -27,6 +27,7 @@ from mininet.topo import SingleSwitchTopo, LinearTopo, SingleSwitchReversedTopo
|
||||
from mininet.topolib import TreeTopo
|
||||
from mininet.util import makeNumeric, custom
|
||||
|
||||
|
||||
def customNode( constructors, argStr ):
|
||||
"Return custom Node constructor based on argStr"
|
||||
cname, newargs, kwargs = splitArgs( argStr )
|
||||
@@ -47,7 +48,6 @@ def customNode( constructors, argStr ):
|
||||
return custom
|
||||
|
||||
|
||||
|
||||
# built in topologies, created only when run
|
||||
TOPODEF = 'minimal'
|
||||
TOPOS = { 'minimal': lambda: SingleSwitchTopo( k=2 ),
|
||||
@@ -229,9 +229,6 @@ class MininetRunner( object ):
|
||||
% self.options.verbosity )
|
||||
lg.setLogLevel( self.options.verbosity )
|
||||
|
||||
# validate environment setup
|
||||
init()
|
||||
|
||||
def begin( self ):
|
||||
"Create and run mininet."
|
||||
|
||||
|
||||
Reference in New Issue
Block a user