0

What is java custom exception ???

Give me simple short cut example and code

18th Jun 2023, 2:52 AM
Radha krishna Matta
Radha krishna Matta - avatar
2 odpowiedzi
+ 5
Radha krishna Matta Plz use search bar and read this before asking any questions.. https://code.sololearn.com/W0uW3Wks8UBk/?ref=app Quick quide... A custom exception in Java is a user-defined exception that extends the Exception class or one of its subclasses. It allows you to create your own exception types that can be thrown and caught in your code. Here's a simple example of a custom exception in Java: ''' public class MyException extends Exception { public MyException(String message) { super(message); } } ''' for more... https://www.javatpoint.com/custom-exception hope it's helpful...happy learning👍.
18th Jun 2023, 5:20 AM
Darpan kesharwani🇮🇳[Inactive📚]
Darpan kesharwani🇮🇳[Inactive📚] - avatar