How does a try statement determine which catch clause
should be used to handle an exception?
Answers were Sorted based on User's Feedback
Answer / guest
when an exception is thrown with in the body of the try
statement then the catch clauses of the try statement are
examined in the order in which they appear.The first catch
clause that is capable of handling the exception is caught
and the remaining are ignored.
Is This Answer Correct ? | 8 Yes | 0 No |
Answer / vatti
when an exception is thrown from the try block,the type of
exception object specified in the catch statement matches
with the exception thrown, that one will execute
Is This Answer Correct ? | 5 Yes | 1 No |
In what ways you can handle exception ?
Explain about serializable interface in java?
How can I become a good programmer?
What are java packages?
What does this () mean in java?
if a java file without any source code is valid java file?
How do you sort a set in java?
what is the Arraylist limit (maximum) by default ?
13 Answers Fidelity, PlanetSoft, Wipro,
What is thread life cycle in java?
Is java jre still free?
Why main() method is public, static and void in java ?
Can we have multiple public classes in a java source file?