开发者

QNetworkAccessManager::put(): uploading large file

开发者 https://www.devze.com 2022-12-24 07:34 出处:网络
I am currently working on a sample application which uses QNetworkAccessManager to send the HTTP command. In the sample we are uploading files to server.Here I want upload the file in chunk by chunk(n

I am currently working on a sample application which uses QNetworkAccessManager to send the HTTP command. In the sample we are uploading files to server. Here I want upload the file in chunk by chunk(not whole file). Is there any way to send la开发者_JAVA百科rge file in chunk by chunk.

Thanks in advance


I think put(const QNetworkRequest&, QIODevice *) will read only chunk-by-chunk from QIODevice. If you want to restrict size of chunk you can create own class inhertied from base in that way that readData(..) will pass further limited value of maxSize.

0

精彩评论

暂无评论...
验证码 换一张
取 消