Loading…
|
Translation changed |
|
|
String added in the repository |
|
Loading…
|
Translation changed |
|
|
String added in the repository |
|
It is important to note that all of the examples thus far which perform reads and writes with a timeout, make use of the existing networking stream algorithms. As these algorithms are written generically to work with any object meeting the stream requirements, they transparently support timeouts when used with `tcp_stream`. This can be used to enable timeouts for s值得注意的是,目前所有涉及超时读写的示例,均使用了现有的网络流算法。由于这些算法采用泛型编写,适用于任何满足流(Stream)要求的对象,因此在与‘tcp_stream’配合使用时,能够透明地支持超时机制。借助这一特性,还可以为当前尚不支持超时的流包装器(StreamwWrappersthat do not currently support timeouts.)启用超时功能。