java - Upload complete event using HttpPost -


my app uploads image server. in order execute uploading, use httppost class. here relevant code fragment:

try {     httpclient httpclient = new defaulthttpclient();     httppost httppost = new httppost("%path_to_server_page%");     httppost.setentity(new urlencodedformentity(namevaluepairs));     httpclient.execute(httppost); } catch (exception e) {     system.out.println("connection error: " + e.tostring()); } 

my question how can raise event , know if uploading has been finished sure file on server?

thanks.

probably, implementation of observer design pattern suitable solution.
reference: https://stackoverflow.com/a/6270150/462347


Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

Rendering JButton to get the JCheckBox behavior in a JTable by using images does not update my table -