+ 1

How is a person supposed to keep all the specific exceptions straight?

There are so many different kinds.

2nd Feb 2016, 9:53 PM
Elizabeth Lewis
Elizabeth Lewis - avatar
4 Respostas
+ 1
@Elizabeth Lewis: You can keep the specific exceptions straight by using the Java documentation. You will become more familiar as you write more code.
1st Mar 2016, 2:33 AM
ItsJustMe
ItsJustMe - avatar
+ 1
we should use a try to execute the statement nd check whether it's wrong nd if it's wrong catch will excute it's statements
25th Mar 2016, 3:09 PM
Rahul Kishan M
Rahul Kishan M - avatar
+ 1
You can use the superclass of them: Exception But if you want to use different codes for different exceptions you dont have to know all of them. some of them are realy rare. Others can be knowed by testing your program and taking xp. Also you can use oracle docs. But remember that if you know some exp types for an issue, others are very similar to them(i man their name).
25th Jun 2016, 10:45 AM
DanI MicraS
DanI MicraS - avatar
+ 1
Specific exceptions if handled by the programmer would give the Code a better perspective in the Developer's world. it's good programming practice to be more specific so that these errors can be corrected and the program execution is smoother. A generic Exception object is almost always recommended at the end of the Catch block to handle any unforeseen errors. As the programmer gets more and more experienced, the programs get more refined and Good programming practices are inculcated in the Code.
7th Sep 2016, 7:55 AM
Naveen Karthik
Naveen Karthik - avatar