phpday 2027 - Call for Papers

The StreamPollHandle class

(PHP 8 >= 8.6.0)

Введение

An Io\Poll\Handle that allows a stream to be watched by an Io\Poll\Context.

Only streams that are backed by a file descriptor of the operating system can be polled, such as sockets and pipes. Which kinds of streams are accepted depends on the backend: for example, Io\Poll\Backend::WSAPoll only accepts sockets, and Io\Poll\Backend::Epoll rejects regular files.

Objects of this class cannot be cloned or serialized.

Обзор класса

final class StreamPollHandle implements Io\Poll\Handle {
/* Методы */
public function __construct(resource $stream)
public function getStream(): resource
public function isValid(): bool
}

Содержание

+Добавить

Примечания пользователей

Пользователи ещё не добавляли примечания для страницы
To Top