title: How to use @Nullable and @Nonnull annotations more effectively?
body: <p>I can see that <code>@Nullable</code> and <code>@Nonnull</code> annotations <em>could</em> be helpful in preventing <code>NullPointerException</code>s but they do not propagate very far.</p>
  
  <ul>
  <li>The effectiveness of these annotations drop off completely after one level of indirection, so if you only add a few they don't propagate very far. </li>
  <li>Since these annotations are not well enforced there is a danger of assuming a value marked with <code>@Nonnull</code> is not null and consequently not performing null checks. </li>
  </ul>
  
  <p>The code below causes a parameter marked with <code>@Nonnull</code> to be <code>null</code> without raising any complaints.  It throws a <code>NullPointerException</code> when it is run.</p>
  
  <pre><code>public class Clazz {
      public static void main(String[] args){
          Clazz clazz = new Clazz();
  
          // this line raises a complaint with the IDE (IntelliJ 11)
          clazz.directPathToA(null);
  
          // this line does not
          clazz.indirectPathToA(null); 
      }
  
      public void indirectPathToA(Integer y){
          directPathToA(y);
      }
  
      public void directPathToA(@Nonnull Integer x){
          x.toString(); // do stuff to x        
      }
  }
  </code></pre>
  
  <p>Is there a way to make these annotations more strictly enforced and/or propagate further?</p>