1:
Default constructor cannot handle exception type UnknownHostException thrown by implicit super constructor. Must define an explicit constructor
翻译:默认构造函数无法处理隐式超级构造函数引发的异常类型UnnownHostException。必须定义显式构造函数
其实就是你写在类的成员中有异常,所以你得将这个成员变量的赋值放在一个方法里面,这样可以抛出异常