I need to do following things:
1. Find the current network bandwidth.
2. Limit the bandwidth to download the file by 50%.
I did some research over this but i am not able to find any good way of doing this.
Like calculating the bandwidth by sending some data for some time and doing some arithmetic over it.
I was wondering if there is any better approach? Since this will take extra time(sending and receiving data+calculating bandwidth). Every time a download request comes i don't want to do it again and again.