开发者

Read Flex/Flash URL which has Transfer-Encoding chunked

开发者 https://www.devze.com 2023-01-13 16:32 出处:网络
I have a problem reading from Flex a url which has Transfer-Encoding: chunked because the FLex waits for the server to send terminate signal which in chunked transfer isn\'t 开发者_如何学编程sent...Us

I have a problem reading from Flex a url which has Transfer-Encoding: chunked because the FLex waits for the server to send terminate signal which in chunked transfer isn't 开发者_如何学编程sent...


Use the URLStream class instead of whatever loader you're using now. Its ProgressEvents will let you read chunks before the message completes.


But if you read the documents a little more carefully, you will find the following. So it becomes clear, you just need to check the size of received chunks until it get ZERO.

The data transfer is terminated by a final chunk of length zero

0

精彩评论

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

关注公众号