title: Proper way to add index columns in greenDao?
body: <p>I am building a data model in greenDAO. It is a port of an iOS app that uses Core Data. In iOS we use indexes (indices?) to increase lookup performance in a table of 20 columns (properties) where 5 columns are frequently queried. I know this results in extra storage and provides slower writes into the table. </p>
  
  <p>Digging in the documentation, I came across the addIndex(Index index) method in <a href="http://greendao-orm.com/javadoc/greendao-generator/index.html?de/greenrobot/daogenerator/Entity.html" rel="noreferrer">Entity</a> and the index() method in <a href="http://greendao-orm.com/javadoc/greendao-generator/de/greenrobot/daogenerator/Property.PropertyBuilder.html" rel="noreferrer">Property.PropertyBuilder</a>. Which is the correct way to add an index to an Entity?</p>
  
  <pre><code>Entity entity = schema.addEntity("entity");
  entity.setSuperclass("SuperClass");
  entity.addIdProperty();
  entity.addIntProperty("property").index();
  </code></pre>
  
  <p>or </p>
  
  <pre><code>Entity entity = schema.addEntity("entity");
  entity.setSuperclass("SuperClass");
  entity.addIdProperty();
  Property property = entity.addIntProperty("property").getProperty();
  entity.setIndex(property);
  </code></pre>
  
  <p>Or do they both do the same thing?</p>