Classes | Functions | Variables
tornado::web Namespace Reference

Classes

class  _linkify
class  _xsrf_form_html
class  Application
class  ChunkedTransferEncoding
class  ErrorHandler
class  FallbackHandler
class  GZipContentEncoding
class  HTTPError
class  OutputTransform
class  RedirectHandler
class  RequestHandler
class  StaticFileHandler
class  TemplateModule
class  UIModule
class  URLSpec

Functions

def _create_signature
def _time_independent_equals
def addslash
def asynchronous
def authenticated
def create_signed_value
def decode_signed_value
def removeslash

Variables

 _auto_finish
 url = URLSpec

Function Documentation

def tornado.web._create_signature (   secret,
  parts 
) [private]

Definition at line 2049 of file web.py.

def tornado.web._time_independent_equals (   a,
  b 
) [private]

Definition at line 1998 of file web.py.

def tornado.web.addslash (   method)
Use this decorator to add a missing trailing slash to the request path.

For example, a request to '/foo' would redirect to '/foo/' with this
decorator. Your request handler mapping should use a regular expression
like r'/foo/?' in conjunction with using the decorator.

Definition at line 1145 of file web.py.

def tornado.web.asynchronous (   method)
Wrap request handler methods with this if they are asynchronous.

If this decorator is given, the response is not finished when the
method returns. It is up to the request handler to call self.finish()
to finish the HTTP request. Without this decorator, the request is
automatically finished when the get() or post() method returns. ::

   class MyRequestHandler(web.RequestHandler):
       @web.asynchronous
       def get(self):
          http = httpclient.AsyncHTTPClient()
          http.fetch("http://friendfeed.com/", self._on_download)

       def _on_download(self, response):
          self.write("Downloaded!")
          self.finish()

Definition at line 1092 of file web.py.

def tornado.web.authenticated (   method)
Decorate methods with this to require that the user be logged in.

Definition at line 1777 of file web.py.

def tornado.web.create_signed_value (   secret,
  name,
  value 
)

Definition at line 2011 of file web.py.

def tornado.web.decode_signed_value (   secret,
  name,
  value,
  max_age_days = 31 
)

Definition at line 2019 of file web.py.

def tornado.web.removeslash (   method)
Use this decorator to remove trailing slashes from the request path.

For example, a request to ``'/foo/'`` would redirect to ``'/foo'`` with this
decorator. Your request handler mapping should use a regular expression
like ``r'/foo/*'`` in conjunction with using the decorator.

Definition at line 1122 of file web.py.


Variable Documentation

Definition at line 1109 of file web.py.

Definition at line 1995 of file web.py.



roswww
Author(s): Jonathan Mace
autogenerated on Thu Jan 2 2014 11:53:30