摘要: public class StaticVariableTest {
private static StaticVariableTest svt = new StaticVariableTest();//语句(1)
private static int count1;//语句(2)
private static int count2 = 0;//语句(3)
private StaticVariableTest(){//语句(4)
count1++;
count2++;
}
public static StaticVariableTest getInstance(){//语句(5)
return svt;
}
public static int getCount1() {
return count1;
}
public
阅读全文