SwingWorker
has...
- Progress change functionality built in, via the
PropertyChange
support - Has helper methods that allow you to synchronise updates to the UI via the
publish
andprocess
methods, making the process significantly easier... - A self contained workflow concept which makes it (generally) easier to use than rolling your own. There are exceptions to the rule, but your outline doesn't fit those exceptions (IMHO) - this is both and advantage and disadvantage...
For example...
- java swingworker thread to update main Gui
- JProgressBar won't update
- Populating jTable using database data (relates to updating a
JTable
from a SQL source, but shows how aSwingWorker
might be used to update aJTable
)
One of the (possible) drawbacks to SwingWorker
is it will only allow (I believe) 10 workers to be executed simultanously