I\'m working on a plugin project in which I\'m using Eclipse background processing.
What\'s the difference between the syncExec() and asyncExec() methods of the Display
SWT implements single threaded UI model. In this model, only the UI-thread can invoke UI operations. If you try and access an SWT object from outside the UI-thread, you get the exception "org.eclipse.swt.SWTException: Invalid thread access". So to allow other threads to perform operations on objects belonging to the UI-thread, SWT provides syncExec and asyncExec methods.
This link may help you with an example