Since Eclipse 3.3 (but it can be done before using a plugin), you can automatically execute actions while saving a Java file:
- organize imports
- format source code
- some other actions (like adding annotations, removing unnecessary casts...)
This can be configured in Preferences > Java > Editor > Save actions.