snakajima / gdispatch

URL routing mechanism for webapp for Google App Engine Developer

Home Page:http://satoshi.blogs.com/uie

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

gdispatch is a simple python module that enables in-place routing instruction right above each RequestHandler.
It also allows RequestHandler to recieve GET/POST parameters as function arguments

Example:

gdispatch.route(lambda:('/login', LoginHandler))
class LoginHandler(webapp.RequestHandler):
    @gdispatch.kwargs
    def post(self, name, password):
        ...    

gdispatch.route(lambda:('/logout', LogoutHandler))
class LogoutHandler(webapp.RequestHandler):
    def get(self):
        ...

gdispatch.run()

About

URL routing mechanism for webapp for Google App Engine Developer

http://satoshi.blogs.com/uie


Languages

Language:Python 100.0%