FindNPE offers a solution for controlling null pointers in Java code. Thus, the risk of NPEs (NullPointerExceptions)
being thrown on customer's side can be minimized. FindNPE offers annotations for a fine-grained control of which variables are allowed to be null at runtime.
Since FindNPE uses static analysis of the Java program at compile time, a program's execution behavior is not affected.

FindNPEs basic rule to reduce NPEs is: If there is a possibility that an object can be null, then compilation errors are produced at places where it is accessed.
This is demonstrated in the following example: