phpday 2027 - Call for Papers

Input/Output

Giriş

The classes of the Io namespace provide a polling API: a way to wait until one of many streams is ready for reading or writing, using the polling mechanism of the operating system. It is intended for programs that handle many connections at once, such as servers and event loops.

The handles to watch are registered with an Io\Poll\Context, which returns an Io\Poll\Watcher for each of them. Io\Poll\Context::wait() then blocks until some of the watchers are triggered. Streams are wrapped in a StreamPollHandle to be watched.

These classes are part of the PHP core and are always available.

+add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top