Tornado 4.5 Documentation
What’s new in Tornado 1.2.1 What’s new in Tornado 1.2 What’s new in Tornado 1.1.1 What’s new in Tornado 1.1 What’s new in Tornado 1.0.1 What’s new in Tornado 1.0 Index Module Index Search Page Discussion and connection def finish(self): self.connection.write_headers( ResponseStartLine("HTTP/1.1", 200, "OK"), HTTPHeaders({"Content-Length": "2"}), b"OK") self.connection Rule(PathMatches("/callable"), request_callable) ]) def request_callable(request): request.write(b"HTTP/1.1 200 OK\r\nContent-Length: 2\r\n\r\nOK") request.finish() 3. Another Router instance: router =0 码力 | 333 页 | 322.34 KB | 1 年前3
Tornado 5.1 Documentation
2. Web framework 45 Tornado Documentation, Release 5.1.1 This method is only supported when HTTP/1.1 is used. New in version 5.1. RequestHandler.get_browser_locale(default=’en_US’) Determines the user’s connection = connection def finish(self): self.connection.write_headers( ResponseStartLine("HTTP/1.1", 200, "OK"), HTTPHeaders({"Content-Length": "2"}), b"OK") self.connection.finish() router = CustomRouter() Rule(PathMatches("/callable"), request_callable) ]) def request_callable(request): request.write(b"HTTP/1.1 200 OK\r\nContent-Length: 2\r\n\r\nOK") request.finish() 3. Another Router instance: router = RuleRouter([0 码力 | 243 页 | 895.80 KB | 1 年前3
Tornado 5.1 Documentation
What’s new in Tornado 1.2.1 What’s new in Tornado 1.2 What’s new in Tornado 1.1.1 What’s new in Tornado 1.1 What’s new in Tornado 1.0.1 What’s new in Tornado 1.0 Index Module Index Search Page Discussion and protocols like websockets that tunnel over an HTTP handshake. This method is only supported when HTTP/1.1 is used. New in version 5.1. RequestHandler.get_browser_locale(default='en_US') Determines the user’s connection def finish(self): self.connection.write_headers( ResponseStartLine("HTTP/1.1", 200, "OK"), HTTPHeaders({"Content-Length": "2"}), b"OK") self.connection0 码力 | 359 页 | 347.32 KB | 1 年前3
Tornado 6.1 Documentation
protocols like websockets that tunnel over an HTTP handshake. This method is only supported when HTTP/1.1 is used. New in version 5.1. RequestHandler.get_browser_locale(default: str = ’en_US’) → tornado connection = connection def finish(self): self.connection.write_headers( ResponseStartLine("HTTP/1.1", 200, "OK"), HTTPHeaders({"Content-Length": "2"}), b"OK") self.connection.finish() router = CustomRouter() Rule(PathMatches("/callable"), request_callable) ]) def request_callable(request): request.write(b"HTTP/1.1 200 OK\r\nContent-Length: 2\r\n\r\nOK") request.finish() 3) Another Router instance: router = RuleRouter([0 码力 | 245 页 | 904.24 KB | 1 年前3
Tornado 6.0 Documentation
protocols like websockets that tunnel over an HTTP handshake. This method is only supported when HTTP/1.1 is used. New in version 5.1. RequestHandler.get_browser_locale(default: str = 'en_US') → tornado connection = connection def finish(self): self.connection.write_headers( ResponseStartLine("HTTP/1.1", 200, "OK"), HTTPHeaders({"Content-Length": "2"}), b"OK") self.connection.finish() router = CustomRouter() Rule(PathMatches("/callable"), request_callable) ]) def request_callable(request): request.write(b"HTTP/1.1 200 OK\r\nContent-Length: 2\r\n\r\nOK") request.finish() 3) Another Router instance: router = RuleRouter([0 码力 | 245 页 | 885.76 KB | 1 年前3
Tornado 6.0 Documentation
What’s new in Tornado 1.2.1 What’s new in Tornado 1.2 What’s new in Tornado 1.1.1 What’s new in Tornado 1.1 What’s new in Tornado 1.0.1 What’s new in Tornado 1.0 Index Module Index Search Page Discussion and protocols like websockets that tunnel over an HTTP handshake. This method is only supported when HTTP/1.1 is used. New in version 5.1. RequestHandler.get_browser_locale(default: str = 'en_US') → tornado connection def finish(self): self.connection.write_headers( ResponseStartLine("HTTP/1.1", 200, "OK"), HTTPHeaders({"Content-Length": "2"}), b"OK") self.connection0 码力 | 869 页 | 692.83 KB | 1 年前3
Tornado 6.1 Documentation
What’s new in Tornado 1.2.1 What’s new in Tornado 1.2 What’s new in Tornado 1.1.1 What’s new in Tornado 1.1 What’s new in Tornado 1.0.1 What’s new in Tornado 1.0 Index Module Index Search Page Discussion and protocols like websockets that tunnel over an HTTP handshake. This method is only supported when HTTP/1.1 is used. New in version 5.1. RequestHandler.get_browser_locale(default: str = 'en_US') → tornado connection def finish(self): self.connection.write_headers( ResponseStartLine("HTTP/1.1", 200, "OK"), HTTPHeaders({"Content-Length": "2"}), b"OK") self.connection0 码力 | 931 页 | 708.03 KB | 1 年前3
Tornado 4.5 Documentation
connection = connection def finish(self): self.connection.write_headers( ResponseStartLine("HTTP/1.1", 200, "OK"), HTTPHeaders({"Content-Length": "2"}), b"OK") self.connection.finish() router = CustomRouter() Rule(PathMatches("/callable"), request_callable) ]) def request_callable(request): request.write(b"HTTP/1.1 200 OK\r\nContent-Length: 2\r\n\r\nOK") request.finish() 3. Another Router instance: router = RuleRouter([ tornado.web. Application. HTTPServer supports keep-alive connections by default (automatically for HTTP/1.1, or for HTTP/1.0 when the client requests Connection: keep-alive). If xheaders is True, we support0 码力 | 222 页 | 833.04 KB | 1 年前3
Tornado 6.4 Documentation
protocols like websockets that tunnel over an HTTP handshake. This method is only supported when HTTP/1.1 is used. New in version 5.1. RequestHandler.get_browser_locale(default: str = 'en_US') → Locale connection = connection def finish(self): self.connection.write_headers( ResponseStartLine("HTTP/1.1", 200, "OK"), HTTPHeaders({"Content-Length": "2"}), b"OK") self.connection.finish() router = CustomRouter() Rule(PathMatches("/callable"), request_callable) ]) def request_callable(request): request.write(b"HTTP/1.1 200 OK\r\nContent-Length: 2\r\n\r\nOK") request.finish() 3) Another Router instance: router = RuleRouter([0 码力 | 268 页 | 1.09 MB | 1 年前3
Tornado 6.4 Documentation
protocols like websockets that tunnel over an HTTP handshake. This method is only supported when HTTP/1.1 is used. New in version 5.1. RequestHandler.get_browser_locale(default: str = 'en_US') → Locale connection = connection def finish(self): self.connection.write_headers( ResponseStartLine("HTTP/1.1", 200, "OK"), HTTPHeaders({"Content-Length": "2"}), b"OK") self.connection.finish() router = CustomRouter() Rule(PathMatches("/callable"), request_callable) ]) def request_callable(request): request.write(b"HTTP/1.1 200 OK\r\nContent-Length: 2\r\n\r\nOK") request.finish() 3) Another Router instance: router = RuleRouter([0 码力 | 268 页 | 1.09 MB | 1 年前3
共 20 条
- 1
- 2













