警报父母我在Java中的以下设置,Java中,对对象的变化
public class Main {
// starts sub class
SubClass sub = new SubClass();
sub.start();
// sub will keep running and call method alert() on a specif change
// method alert is void but updates a public variable named status on sub
while(1==1) {
// I should ideally be able to catch/read sub status result here
// how can I do it?
}
}
我是新来的Java所以这可能是无效的,我的做法可能是错误的。既然如此,请指向正确的方向。
谢谢。
你的问题是什么? – 2010-11-16 23:15:07