Class NotFoundException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
com.iizix.NotFoundException
- All Implemented Interfaces:
Serializable
The not found exception is thrown when an object by reference or name is not found: a VirtualSpace or UI component looked up by name or path, a user, a group, a mail sender, a string ID or a file. It is unchecked: a lookup that cannot miss needs no clause, and a caller that handles the miss catches it by name.
Until CC-FIX-NOTFOUND-AND-RESET this class extended Error (from r13200, 2018). That was a trap: a catch ( Exception ) written around a lookup to handle the miss did not catch it, so the miss went on to the next catch ( Throwable ) up the stack and the handler's own recovery never ran - 17 such blocks at r20195 (CC-SURVEY-NOTFOUND), 11 of them in ServerAdmin. A catch ( Exception ) around a lookup now catches it; a catch ( Error ) no longer does.
- Author:
- Christopher Mindus
- See Also:
Constructor Summary
ConstructorsConstructorDescriptionNotFoundException(String message) Constructs a not found exception with just a message text.NotFoundException(String message, Throwable cause) Constructs a not found exception with a nested exception.Method Summary
Methods inherited from class Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
Constructor Details
NotFoundException
Constructs a not found exception with just a message text.- Parameters:
message- The text message of the exception.
NotFoundException