--最简单、最粗暴、单线程、多线程、最安全的单例模式
public class A {
private static A a =new A();
private A(){}
public static A getInstance(){
return a;
}
}
--最简单、最粗暴、单线程、多线程、最安全的单例模式
public class A {
private static A a =new A();
private A(){}
public static A getInstance(){
return a;
}
}