Also, if there is a chance that more than one thread might delete the object, the merged approach might not always work. In this situation, it is better to maintain separate synchronization objects.
同时,如果存在超过一个线程会删除对像,这种合并的方法可能会工作异常,在这种情况下,最好是分开维护同步对像。
Also, if there is a chance that more than one thread might delete the object, the merged approach might not always work.
而且,如果有一个以上的线程可能删除对象,合并方法不一定始终有效。
应用推荐