title: Creating java class with annotated fields in runtime
body: <p>The problem is that I need to create in runtime a class like this:</p>
  
  <pre><code>public class Foo {
    @Bar int value0;
    @Bar int value1;
    @Bar int value2;
  ....
  }
  </code></pre>
  
  <p>with number of fields being decided at runtime.</p>
  
  <p>I was looking at Javassist, and there you can create a new class, and add fields to it, but I haven't found a way to annotate those fields.</p>