What is the need of "creating and throwing an
UserdefinedException" when the "Exception" class is already
available?

Answer Posted / sri

if you want you could specify your own exception that you
know is gonna happen otherwise it is recommended to handle
the exception through exception class in catch block.

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between member variables initialization and assignment in a constructor?

655


What is local class in java?

514


What is linked hashset and its features?

541


What is the basic concepts of OOPS?

681


What comes to mind when someone mentions a shallow copy in java?

649






What is the difference between a local variable and an instance variable?

544


How to invoke external process in java.

559


What is OOP Language?

622


What is data type in java?

483


What are the various access specifiers in java?

561


What is basic syntax?

543


What is difference between char array and string?

523


What is an example of procedure?

510


What is preflight request?

524


In a container there are 5 components. I want to display the all the components names, how will you do that one?

602