Listing 6 shows the logic for identifying RuntimeException capture.
清单6显示了用于标识RuntimeException捕获的逻辑。
So, in your situation: your application exception classes are subclasses of RuntimeException.
因此,对于您的情况:您的应用程序异常类是RuntimeException的子类。
In Listing 3, I've ensured that a RuntimeException will be thrown if push with null is called.
在清单3中,我确保了如果对null调用push,则抛出一个RuntimeException。
应用推荐