Webclient下载速度限制 [英] Webclient download speed limit

查看:251
本文介绍了Webclient下载速度限制的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的自动更新软件中,我使用WebClient下载更新文件,但是如何限制下载速度?

解决方案

AFAIK,这不会可能在WebClient 级别.
您将需要查看网络设置以进行控制-在客户端或服务器上.


使用WebClient,您不需要.它将以与发送文件的服务器一样快的速度下载,并且您的网络连接可以处理.

如果要加快下载速度,则必须实现自己版本的WebClient类(使用TCP套接字),以便您可以自己加快每个数据块的下载速度.


In my auto update software,I use the WebClient to download updatefiles,but how do I limit the speed of download?

解决方案

AFAIK, This will not be possible at the WebClient level.
You will need to look at the network settings to control this - either on client or server.


Using the WebClient, you don''t. It''ll download as fast as the server sending the file and your network connection can handle.

If you want to pace the download, you''ll have to implement your own version of the WebClient class (using TCP sockets) so you can pace the download of each block of data yourself.


这篇关于Webclient下载速度限制的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆