Loading…
|
Translation changed |
|
|
String added in the repository |
|
Loading…
|
Translation changed |
|
|
String added in the repository |
|
Authors using Beast can reuse the library's primitives to create their own initiating functions for performing a series of other, intermediate asynchronous operations before invoking a final completion handler. The set of intermediate actions produced by an initiating function is known as a [@http://blog.think-async.com/2009/08/composed-operations-coroutines-and-code.html ['composed operation]]. To ensure full interoperability and well-defined behavior, __Asio__ imposes requirements on the implementation of composed operations. These classes and functions make it easier to develop initiating functions and their composed operations:使用 Beast 的开发者可以复用库中的基本组件,来创建自己的发起函数。这些发起函数会在执行一系列中间异步操作之后,最终调用一个完成处理器。发起函数所产生的这一系列中间动作,被称为 [组合操作]。为确保良好的互操作性和行为的一致性,__Asio__ 对组合操作的实现方式提出了一些要求。以下提供的类和函数,可以帮助开发者更轻松地编写发起函数及其对应的组合操作: