title: Annotate anonymous inner class
body: <p>Is there a way to annotate an anonymous inner class in Java?</p>
  
  <p>In this example could you add a class level annotation to Class2?</p>
  
  <pre><code>public void method1() {
    add(new Class2() {
      public void method3() {}
    });
  }
  </code></pre>