在java中向下转型时必须在之前有个 子类实列化父类对象 如 class A{} class B extends A{} A a=new B(); B b=(B)a;//对的 A a=new A(); B b=(B)a//不对