title: How to use Android Support typedef annotations in kotlin?
body: <p>I develop Android applications and often use annotations as compile time parameter checks, mostly android's <a href="http://tools.android.com/tech-docs/support-annotations" rel="noreferrer">support annotations</a>.</p>
  
  <p>Example in java code:</p>
  
  <pre><code>public class Test
  {
      @IntDef({Speed.SLOW,Speed.NORMAL,Speed.FAST})
      public @interface Speed
      {
           public static final int SLOW = 0;
           public static final int NORMAL = 1;
           public static final int FAST = 2;
      }
  
      @Speed
      private int speed;
  
      public void setSpeed(@Speed int speed)
      {
          this.speed = speed;
      }
  }
  </code></pre>
  
  <p>I don't want to use enums because of their performance issues in Android. The automatic converter to kotlin just generates invalid code. How do I use the <code>@IntDef</code> annotation in kotlin?</p>