May 2019
Intermediate to advanced
546 pages
12h 41m
English
You just learned how to build a custom Exceptions class to extend the Apex Exception class. But what's the Exception class?
In each exception, you can get the error message, the location of the error, and the path of the error. For instance, you have a method in class A, called by a method in class B, and you caught the exceptions in class B. You don't need to look in class B, but in class A. The exception will tell you where you need to start your troubleshooting. Even the line number, the type of exception (callout error, Nullpointer, QueryException, and DMLException) are present in the Exception class.
The following are the methods of the Exception class that you can use in your error handling:
Read now
Unlock full access