(PHP 5 >= 5.2.0, PHP 7, PECL swoole >= 1.9.0)
类摘要
Swoole\Client
{
public bool close
([
bool $force
] )
public bool connect
(
string $host
[,
integer $port
[,
integer $timeout
[,
integer $flag
]]] )
public void on
(
string $event
,
callable $callback
)
public void pause
(
void
)
public void pipe
(
string $socket
)
public void recv
([
string $size
[,
string $flag
]] )
public integer send
(
string $data
[,
string $flag
] )
public boolean sendfile
(
string $filename
[,
int $offset
] )
public boolean sendto
(
string $ip
,
integer $port
,
string $data
)
public void set
(
array $settings
)
public void sleep
(
void
)
}
属性
- errCode
-
- sock
-
- reuse
-
- reuseCount
-
预定义常量
Swoole\Client::MSG_OOB
-
Swoole\Client::MSG_PEEK
-
Swoole\Client::MSG_DONTWAIT
-
Swoole\Client::MSG_WAITALL
-