跳到主要内容

connect

连接服务器

声明

bool connect(string host, int port, int timeout = 5)

参数

参数名描述
host- 服务器主机
port- 服务器端口
timeout- 连接超时时间

返回值

true - 连接成功, false - 连接失败

使用方式

返回文档