O'Reilly logo

OCP Java SE 8 Programmer II Exam Guide (Exam 1Z0-809), 7th Edition by Elisabeth Robson, Bert Bates, Kathy Sierra

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Images

3

Assertions and Java Exceptions

CERTIFICATION OBJECTIVES

•       Use try-catch and throw Statements

•       Use catch, Multi-catch, and finally Clauses

•       Use Autoclose Resources with a try-with-resources Statement

•       Create Custom Exceptions and Auto-closeable Resources

•       Test Invariants by Using Assertions

Images     Two-Minute Drill

Q&A   Self Test

The assertion mechanism gives you a way to do testing and debugging checks on conditions you expect to smoke out while developing, when you don’t want the runtime overhead associated with ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required