Handling Errors: Advanced Topics in Exceptions
Java JDK 9+
| Intermediate
- 6 videos | 43m 21s
- Includes Assessment
- Earns a Badge
While handling exceptions is enough for most programmers, if you are building an app that other developers consume, you should know how to throw exceptions proactively and the various options available in Java in this regard. This is precisely the focus of this course. Learn about throwing an exception based on your conditions in a Java program and how nested function calls influence exception throwing and handling. You'll get a chance to explicitly throw an exception using the throw keyword, add complexity to your code by throwing different exceptions based on different conditions, and build a customized Exception class to define an exception that is not covered by Java's library. Having finished this course, you'll have the knowledge to throw exceptions and run your program without breaking its flow.
WHAT YOU WILL LEARN
-
discover the key concepts covered in this courseuse the throw keyword in Java to explicitly throw an exception when the state of the program does not match your own set of valid conditionsinvoke multiple exceptions in your program based on different error conditions
-
throw and handle exceptions at various levels when nested function calls are involveddefine your exception class by extending Java's built-in Exceptionsummarize the key concepts covered in this course
IN THIS COURSE
-
2m 25sIn this video, you’ll learn more about your instructor and this course. In this course, you’ll learn how you can throw an exception based on your own set of conditions in Java. You’ll employ the throw keyword to… FREE ACCESS
-
11m 37sIn this video, you’ll learn about proactively throwing an exception. You’ll see this is especially useful if you build interfaces that are consumed by other developers. In this demo, you’ll see there's a new source… FREE ACCESS
-
10m 14sIn this video, you’ll watch a demo. In this demo, you’ll build upon the last demo and define a function that can throw two exceptions. To start off, you’ll clear out the main function, and then in the inputs, beyond the… FREE ACCESS
-
8m 36sIn this video, you’ll watch a demo. In this demo, you’ll see it’s possible to spread the handlers across the call stack methods. You’ll leave the validateStudent function as is, but you’ll modify the intermediateFunction.… FREE ACCESS
-
8m 36sIn this video, you’ll watch a demo. In this demo, you’ll see that you might need to define your own exception classes. You’ll learn how to do that here. Onscreen, you’ll see a new class within your project called… FREE ACCESS
-
1m 52sIn this video, you’ll summarize what you’ve learned in this course. In this course, you’ve learned how to throw exceptions proactively and the various options available in Java in this regard. You learned how to throw an… FREE ACCESS
EARN A DIGITAL BADGE WHEN YOU COMPLETE THIS COURSE
Skillsoft is providing you the opportunity to earn a digital badge upon successful completion on some of our courses, which can be shared on any social network or business platform.
Digital badges are yours to keep, forever.