| Phadhail model impl using a technique like SwingWorker.
Fairly complicated. Methods are broken down into several categories:
1. Simple methods like delete() will just block on the work thread.
2. Ditto hasChildren(), but the result is cached.
3. name + path return a dummy initial value and later fire a change.
4. Ditto children, but then the results must be wrapped too.
5. create* also wraps results.
6. Listeners are added asynch and their callbacks must be posted back to AWT too.
For a more complex model, you could use Proxy to do this stuff, if there some kind
of map giving the desired thread behavior of each method.
author: Jesse Glick |