static 声明静态类!
静态类不用实例化可以直接调用。

解决方案 »

  1.   

    Static Initializers
    • A class can contain code in a static block that does not
    exist within a method body.
    • Static block code executes only once, when the class is
    loaded.
    • A static block is usually used to initialize static (class)
    attributes.
      

  2.   

    第一问:A里面的static段叫做 class A的类构造方法,叫class contructor。
    第二问:对B没有影响。
    补充:class constructor与instance constructor是不同的。
    如下的例子里分别说明了class contrcutro和instance condtructor
    class A{
    static {}
      public A()
    {}}
      

  3.   

    再补充:
    class contructor是在类第一次被ClassLoader加载时执行的。
    instance contrcutor是在类第一次被实例化时被执行的。
      

  4.   

    类A里面的static是声明一些静态方法、变量等,其它地方调用时不用实例化。Static方法和属性可以继承,B从A类继承的,所以也起作用。
      

  5.   

    got it! 
    thanks All!
    especially to wswhp(greenland) and feiyuegaoshan(飞跃)!
    I think answers from you two are more appropriate.
    you all, really help!