User defined exception are checked or unchecked exceptions

前端 未结 5 2073
后悔当初
后悔当初 2021-01-21 07:52

In my web application created a User defined exception extends with Exception.Is it Checked or unchecked exception

public class InvalidDataException extends Exc         


        
5条回答
  •  悲&欢浪女
    2021-01-21 08:40

    THere are two classes call as partially checked exception.

    1.) Exception class

    2.) throwable class

    It calls partially checked because some of their subclasses are Unchecked. So you have extended the Exception class then it's Checked exception

提交回复
热议问题