def DefaultController(name, controllers=DefaultControllers, **kwargs):
 controller = findController(controllers)
 if (not controller):
  raise Exception('Could not find a default OpenFlow controller')
 return controller(name, **kwargs)

def DefaultController ( name , controllers = DefaultControllers , ** kwargs ) : controller = findController ( controllers ) if ( not controller ) : raise Exception ( 'Could not find a default OpenFlow controller' ) return controller ( name , ** kwargs )
find a controller that is available and instantiate it .