我想在Java中创建一个自定义异常,该怎么办?
...
try{
...
String word=reader.readLine();
if(word.contains(" "))
/*create custom exception*/
}
catch(){
当我使用创建自定义异常时throw new...,出现错误unreported exception...must be caught or declared to be thrown
米琪卡哇伊
拉莫斯之舞
慕斯王
随时随地看视频慕课网APP
相关分类