/// <summary> /// Converts a string to an instance <see cref="Socks4aProxyClient"/>. /// </summary> /// <param name="proxyAddress">String type - host: port: username: password. The last three are optional.</param> /// <returns>An instance <see cref="Socks4aProxyClient"/>.</returns> /// <exception cref="System.ArgumentNullException">parameter <paramref name="proxyAddress"/> equally <see langword="null"/>.</exception> /// <exception cref="System.ArgumentException">parameter <paramref name="proxyAddress"/> is an empty string.</exception> /// <exception cref="System.FormatException">port format is wrong.</exception> public static Socks4aProxyClient Parse(string proxyAddress) { return(ProxyClient.Parse(ProxyType.Socks4a, proxyAddress) as Socks4aProxyClient); }
/// <summary> /// Converts a string to an instance <see cref="HttpProxyClient"/>. /// </summary> /// <param name="proxyAddress">String type - host:port:username:password. The last three are optional.</param> /// <returns>An instance <see cref="HttpProxyClient"/>.</returns> /// <exception cref="System.ArgumentNullException">parameter <paramref name="proxyAddress"/> equally <see langword="null"/>.</exception> /// <exception cref="System.ArgumentException">parameter <paramref name="proxyAddress"/> It is an empty string.</exception> /// <exception cref="System.FormatException">port format is wrong.</exception> public static HttpProxyClient Parse(string proxyAddress) { return(ProxyClient.Parse(ProxyType.Http, proxyAddress) as HttpProxyClient); }