Fixing pep8 errors
This commit is contained in:
parent
5626c2fedd
commit
ec5b5dd523
@ -24,6 +24,7 @@ methods that needs to be implemented by a Quantum Plug-in.
|
|||||||
|
|
||||||
from abc import ABCMeta, abstractmethod
|
from abc import ABCMeta, abstractmethod
|
||||||
|
|
||||||
|
|
||||||
class QuantumPluginBase(object):
|
class QuantumPluginBase(object):
|
||||||
|
|
||||||
__metaclass__ = ABCMeta
|
__metaclass__ = ABCMeta
|
||||||
|
@ -17,24 +17,27 @@
|
|||||||
|
|
||||||
import json
|
import json
|
||||||
import routes
|
import routes
|
||||||
|
from common import wsgi
|
||||||
from webob import Response
|
from webob import Response
|
||||||
|
|
||||||
from common import wsgi
|
|
||||||
|
|
||||||
class NetworkController(wsgi.Controller):
|
class NetworkController(wsgi.Controller):
|
||||||
|
|
||||||
def version(self,request):
|
def version(self, request):
|
||||||
return "Quantum version 0.1"
|
return "Quantum version 0.1"
|
||||||
|
|
||||||
|
|
||||||
class API(wsgi.Router):
|
class API(wsgi.Router):
|
||||||
def __init__(self, options):
|
def __init__(self, options):
|
||||||
self.options = options
|
self.options = options
|
||||||
mapper = routes.Mapper()
|
mapper = routes.Mapper()
|
||||||
network_controller = NetworkController()
|
network_controller = NetworkController()
|
||||||
mapper.resource("net_controller", "/network", controller=network_controller)
|
mapper.resource("net_controller", "/network",
|
||||||
|
controller=network_controller)
|
||||||
mapper.connect("/", controller=network_controller, action="version")
|
mapper.connect("/", controller=network_controller, action="version")
|
||||||
super(API, self).__init__(mapper)
|
super(API, self).__init__(mapper)
|
||||||
|
|
||||||
|
|
||||||
def app_factory(global_conf, **local_conf):
|
def app_factory(global_conf, **local_conf):
|
||||||
conf = global_conf.copy()
|
conf = global_conf.copy()
|
||||||
conf.update(local_conf)
|
conf.update(local_conf)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user