setupProxy method
设置代理(不支持Web)
Implementation
void setupProxy(String host, int port) {
_client!.httpClientAdapter = IOHttpClientAdapter(
createHttpClient: () {
final client = HttpClient();
client.findProxy = (uri) => 'PROXY $host:$port';
client.badCertificateCallback =
(X509Certificate cert, String host, int port) => true;
return client;
},
);
}