Tornado 6.5 Documentation
http_client = AsyncHTTPClient() response = await http_client.fetch(url) return response.body Or for compatibility with older versions of Python, using the tornado.gen module: 14 Chapter 6. DocumentationTornado and await keywords (functions using these keywords are also called “native corou- tines”). For compatibility with older versions of Python, you can use “decorated” or “yield-based” coroutines using the tornado Native coroutines are the recommended form whenever possible. Only use decorated coroutines when compatibility with older versions of Python is required. Examples in the Tornado documentation will generally0 码力 | 272 页 | 1.12 MB | 2 月前3Tornado 6.5 Documentation
AsyncHTTPClient() response = await http_client.fetch(url) return response.body Or for compatibility with older versions of Python, using the tornado.gen module: from tornado.httpclient import AsyncHTTPClient and await keywords (functions using these keywords are also called “native coroutines”). For compatibility with older versions of Python, you can use “decorated” or “yield-based” coroutines using the tornado Native coroutines are the recommended form whenever possible. Only use decorated coroutines when compatibility with older versions of Python is required. Examples in the Tornado documentation will generally0 码力 | 437 页 | 405.14 KB | 2 月前3Rust 程序设计语言 简体中文版 1.85.0
文件名:src/lib.rs mod front_of_house { mod hosting { fn add_to_waitlist() {} fn seat_at_table() {} } mod serving { fn take_order() {} fn serve_order() {} fn 中模块树的结构。 crate └── front_of_house ├── hosting │ ├── add_to_waitlist │ └── seat_at_table └── serving ├── take_order ├── serve_order └── take_payment 示例 7-2: count。这个可变引用在 for 循环的结尾离开作用域, 这样所有这些改变都是安全的并符合借用规则。 哈希函数 HashMap 默认使用一种叫做 SipHash 的哈希函数,它可以抵御涉及哈希表(hash table) 的 拒绝服务(Denial of Service, DoS)攻击。然而这并不是可用的最快的算法,不过为了更高的 安全性值得付出一些性能的代价。如果性能监测显示此哈希函数非常慢,以致于你无法接受,0 码力 | 562 页 | 3.23 MB | 8 天前3
共 3 条
- 1