title: Java Function Annotation Help, use @Deprecated?
body: <p><strong>Scenario:</strong><br>
  Java 1.6</p>
  
  <pre><code>class Animal { 
      private String name; 
      ...  
      public String getName() { return name; }  
      ...
  }
  
  class CatDog extends Animal {
      private String dogName;
      private String catName;
      ...
      public String getDogName() { return dogName; }
      public String getCatName() { return catName; }
      public String[] getNames() { return new String[]{ catName, dogName }; }
      ...
      public String getName() { return "ERROR! DO NOT USE ME"; }
  }
  </code></pre>
  
  <p><strong>Problem:</strong><br>
  getName doesn't make sense and shouldn't be used in this example. I'm reading about @Deprecated annotation. Is there a more appropriate annotation method?</p>
  
  <p><strong>Questions:</strong><br>
  A) Is it possible to force an error when this function is used (before runtime)?<br>
  B) Is there a way to display a customized warning/error message for the annotation method I will use? Ideally when the user is hovering over deprecated/error function.</p>