摘要: 单例模式实现*(创建一个类,只能生成该类的一个实例) public class singleDog { //创建对象 private static singleDog si=new singleDog(); //私有化构造方法 private singleDog(){ } //饿汉模式,线程安全,效... 阅读全文
posted @ 2018-02-01 22:40 皇后 阅读(137) 评论(0) 推荐(0) 编辑