暂停代码如下:
$this->synchronized(function($thread){
if (!$thread->done)
$thread->wait();
}, $this);
唤醒代码如下:
$my->synchronized(function($thread){
$thread->done = true;
$thread->notify();
}, $my);
那么......那个thread->done到底是个什么玩意?为什么我去掉了程序依然跑得通?
恳请各位大佬指点迷津。
蓝山帝景