paulb@292 | 1 | #!/usr/bin/env python |
paulb@292 | 2 | |
paulb@292 | 3 | from WebStack.Adapters import JavaServlet |
paulb@292 | 4 | from Auth import AuthResource, AuthAuthenticator |
paulb@292 | 5 | from javax.servlet.http import HttpServlet |
paulb@292 | 6 | |
paulb@292 | 7 | class AuthApp(HttpServlet): |
paulb@292 | 8 | def __init__(self): |
paulb@292 | 9 | HttpServlet.__init__(self) |
paulb@292 | 10 | self.dispatcher = JavaServlet.Dispatcher(AuthResource(), AuthAuthenticator()) |
paulb@292 | 11 | |
paulb@292 | 12 | def service(self, request, response): |
paulb@292 | 13 | self.dispatcher.service(request, response) |
paulb@292 | 14 | |
paulb@292 | 15 | # vim: tabstop=4 expandtab shiftwidth=4 |