title: compare an object to null!
body: <p>I am trying to verify whether an object is null or not and i am using this syntax:</p>
  
  <pre><code>void renderSearch(Customer c){
           System.out.println("search customer rendering&gt;...");
           try {
               if(!c.equals(null)){            
                   System.out.println("search customer  found...");
               }else{               
                   System.out.println("search customer not found...");
               }
           } catch (Exception e) {
               System.err.println ("search customer rendering error: "
                                       + e.getMessage()+"-"+e.getClass());
           }
       }
  </code></pre>
  
  <p>I get the following exception :</p>
  
  <blockquote>
    <p>search customer rendering error: null
    class java.lang.NullPointerException</p>
  </blockquote>
  
  <p>I thought that I was considering this possibility with my if and else loop.  Any help would be appreciated.</p>