略微加速

PHP官方手册 - 互联网笔记

PHP - Manual: Swoole\Channel::push

2024-12-22

Swoole\Channel::push

(PECL swoole >= 1.9.0)

Swoole\Channel::pushWrite and push data into Swoole channel.

说明

public Swoole\Channel::push(string $data): bool

Data can be any non-empty PHP variable, the variable will be serialized if it is not string type.

If size of the data is more than 8KB, swoole channel will use temp files storage.

The function will return true if the write operation is succeeded, or return false if there is not enough space.

参数

data

The data to push into the Swoole channel.

返回值

Wheter the data is pushed into he Swoole channel.

add a noteadd a note

User Contributed Notes

There are no user contributed notes for this page.

官方地址:https://www.php.net/manual/en/swoole-channel.push.php

北京半月雨文化科技有限公司.版权所有 京ICP备12026184号-3