我正在从服务器下载文件并且文件已成功下载现在我想通过进度条显示下载进度。我的代码低于>>
private ObjectInputStream in;
in=new ObjectInputStream(socket.getInputStream());
Data data1 = (Data) in.readObject();
FileOutputStream fos = new FileOutputStream("C:\\Users\\jabir\\Desktop\\"+data1.getName());
fos.write(data1.getFile());