java.util.Observable, will clients complete executing their update() before continuing

Posted by jax on Stack Overflow See other posts from Stack Overflow or by jax
Published on 2010-06-01T19:16:43Z Indexed on 2010/06/01 19:23 UTC
Read the original article Hit count: 141

Filed under:

When I call:

    setChanged();
notifyObservers()

on a java.until.Observable class, will all the listening Observer objects complete execution of their udpate() methods - assuming we are running in the same Thread - before the java.until.Observable class continues running?

This is important because I will be sending a few messages through the notifyObservers(Object o) method in quick concession, it is important that each Observer class has finished its method before the new one though.

I understand that the order of execution for each Observer class may vary when we call notifyObservers() - it is just important that the order of method execution for each individual instance is in order.

© Stack Overflow or respective owner

Related posts about java