单例模式两种书写方式
摘要:
两种都是静态的 1、 public class Single{private Single(){ 立即加载private static Single s= new Single();public static Single getSingle(){ return s; } } 2、 public c 阅读全文
posted @ 2019-11-11 22:22 花痴の 阅读(162) 评论(0) 推荐(0)
2019年11月11日 #
posted @ 2019-11-11 22:22 花痴の 阅读(162) 评论(0) 推荐(0)
posted @ 2019-11-11 22:20 花痴の 阅读(145) 评论(0) 推荐(0)
posted @ 2019-11-11 22:18 花痴の 阅读(118) 评论(0) 推荐(0)
2019年10月27日 #
posted @ 2019-10-27 22:22 花痴の 阅读(179) 评论(0) 推荐(0)
posted @ 2019-10-27 22:21 花痴の 阅读(106) 评论(0) 推荐(0)
2019年10月20日 #