JAVA多线程设计模式四 Balking Pattern
?
?
public class Main { public static void main(String[] args) { Data data = new Data("data.txt", "(empty)"); new ChangerThread("ChangerThread", data).start(); new SaverThread("SaverThread", data).start(); }}?
?
条件不满足,则跳过。并不wait()