Progress bar to download files?

I use servlets to upload files in my web application. I want to show a progress bar at boot time. I looked through some examples of Ajax + Progresslistener, one here .

In the doPost () method, they create a session object and set a new Listener attribute. Also, my previous code and tutorial code for the doPost () method is the same.

My question is they are setting the Listener Attribute one time, at the beginning. How it will update the bytesRead frequently (I'm new to this, so my questions may be unfounded)

In the doGet () method, they extract the Listener attribute and extract the necessary information from it.

This part also, i am not able to understand. They are not implementing ProgressListener class(Searches, led me to this Class).

I know several DWRs. Thus, I can use it to get information about data transfer from the server, if I understand the process on the server side, to update the data transfer.

Anyone explain to me the server side process?

Or any links or suggestions would be accurate at the moment !!!

Thank!

+1
source share
1 answer

Source: https://habr.com/ru/post/1775141/


All Articles