直接使用异常的父类,exception e 捕获所有异常
try{代码。。。。。。。。。。} catch ( Exception e) {e.printStackTrace();}当然你如果知道你要捕捉的具体异常 你可以直接指定 xxxexception ;