Does java has library exception class which means actually not an error, but good termination? I know I can make my own class or use null, but wish to know.
EDIT 1
I want to use exception object as an old fashion return code for a method, so I need something equivalent to ERROR_SUCCESS code in Win32 API.
To directly answer your question: No. There is no standard Java exception that means “this is a normal termination”.
If you wanted to, you could define a custom exception that meant this for your application.
However,
… using an exception for “normal control flow” goes against the strong recommendations of the Java designers, and a Java “Best Practice” rule that has pretty much universal acceptance. This is not to say you should NEVER do this. It is just that the cases where it is justifiable to do this are VERY RARE. (And you’d need to take special steps to avoid grossly inefficient code … )
Anyway, the fact that it is (almost) always a terrible idea to use exceptions for normal flow control explains why a standard exception was never created. The Java designers clearly didn’t want to appear to be encouraging this practice.