Tagged: #exceptions

ClassNotFoundException vs NoClassDefFoundError

ClassNotFoundException vs NoClassDefFoundError

ClassNotFoundException and NoClassDefFoundError occur when a required class is not found in the classpath at runtime. In this tutorial, we resolve the conflict between these 2 exceptions and explain the different...

Java try-with-resources

Java try-with-resources

Java 7 supports a new statement called try-with-resources which extends the behavior of the traditional try/catch block for the sake of automatic resource management, since Java 7 developers are able...

Exception handling strategy

Exception handling strategy

In this article we introduce a common strategy for handling exceptions in an OOP application, our strategy conforms to the best exception handling techniques and can be integrated in any...

How to use exceptions effectively

How to use exceptions effectively

Exception is an event which occurs during the execution of a program and disrupts its normal flow, it is mainly arrised from different kind of situations such as wrong user...