Thread-Safe Interface (线程安全接口) : 将加锁开销减至最少,并保证组件间的方法调用不会因为想再次获得一个已被组件拥有的锁而导致的“自死锁”.
基于40个网页-相关网页
线程安全接口
Thread-safe interface
以上为机器翻译结果,长、整句建议使用 人工翻译 。
为了确保实现是线程安全的,实现该接口的类应该在方法上使用synchronized关键字,或者在方法内部使用同步锁。
To ensure that your implementation is thread-safe, a class that implements this interface should use either the synchronized keyword on the methods or synchronized blocks within the methods.
youdao
应用推荐
模块上移
模块下移
不移动