Originally posted by Vernon Gibson:
Now, if there are several instances of Class1 running on the same machine, can I be assured that a given Class2 will be referencing only the Class1 that started it?
No. There is
no isolation whatsoever between Threads.
The only way you can assure that your instance of Class2 will refer to the right instance of Class1 is by simply giving it the right Class1 object to work with (note that you will get this automatically if Class2 is a non-static inner class of Class1).
- Peter