Skip to content
Snippets Groups Projects
Commit e30f2c99 authored by Bob Lantz's avatar Bob Lantz
Browse files

Rename Controller.controller to .command

parent 55ca2d0c
No related branches found
No related tags found
No related merge requests found
...@@ -181,12 +181,12 @@ def addSwitch( self, name, mac=None, ip=None ): ...@@ -181,12 +181,12 @@ def addSwitch( self, name, mac=None, ip=None ):
self.nameToNode[ name ] = sw self.nameToNode[ name ] = sw
return sw return sw
def addController( self, name='c0', Controller=None, **kwargs ): def addController( self, name='c0', controller=None, **kwargs ):
"""Add controller. """Add controller.
Controller: Controller class""" controller: Controller class"""
if not Controller: if not controller:
Controller = self.controller controller = self.controller
controller_new = Controller( name, **kwargs ) controller_new = controller( name, **kwargs )
if controller_new: # allow controller-less setups if controller_new: # allow controller-less setups
self.controllers.append( controller_new ) self.controllers.append( controller_new )
self.nameToNode[ name ] = controller_new self.nameToNode[ name ] = controller_new
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment