Java exception handling

后端 未结 7 1272
無奈伤痛
無奈伤痛 2020-12-02 00:37

How do I use exceptions and exception handling to make my program continue even if an exception occurs while processing certain files in a set of files?

I want my pr

7条回答
  •  栀梦
    栀梦 (楼主)
    2020-12-02 01:07

    FileSystemException may be the specific exception you are looking for.

    Although, a better idea for beginners is to catch an exception and print it using

    System.out.println(e);

    where e is the caught exception.

提交回复
热议问题