writeCgi method
发送CGI指令 底层封装CGI数据格式
Implementation
Future<bool> writeCgi(String cgi,
{int timeout = 5, bool needLogin = true}) async {
if (p2pConnectState != ClientConnectState.CONNECT_STATUS_ONLINE) {
return false;
}
int clientPtr = await getClientPtr();
bool bl =
await AppP2PApi().clientWriteCgi(clientPtr, cgi, timeout: timeout);
if (bl != true) {
bl = await AppP2PApi().clientWriteCgi(clientPtr, cgi, timeout: timeout);
}
return bl;
}