Dict.CN 在线词典, 英语学习, 在线翻译 ------------- MyGitee My腾云code My51cto

Happy_EveryDay

可以平凡 不可以平庸 无爱则无忧,无欲则无求,无怒而无敌,无怨才是佛。所有烦恼,都是放不下的执著 开源技群 328035181 MyGitee

博客园 首页 管理

2021年4月6日 #

摘要: 1、wait 使用说明 public class Thread001 { class Res{ public String userName; private char sex; private boolean flag; } class InputThread extends Thread{ Re 阅读全文
posted @ 2021-04-06 10:32 2026cn 阅读(107) 评论(0) 推荐(0)

摘要: 当前线程变为阻塞(释锁) 放弃CPU执行 在同步代码块中使用且必须要通过对象.wait(this.wait) 释锁目的: 生产者写数据,防死锁 public class Thread002 { public static void main(String[] args) { new Thread00 阅读全文
posted @ 2021-04-06 00:52 2026cn 阅读(85) 评论(0) 推荐(0)