Skip to content

Eclipse Project Configuration

shuya-inc edited this page Feb 21, 2012 · 3 revisions

Once you have downloaded AndroidAnnotations, you may add it to your projects.

Warning: Make sure executing java -version in a prompt shows version 1.6.X.

Warning: Annotation processing is not well implemented on Eclipse 3.4.X. Please use at least Eclipse 3.5.

Note: If you use Maven in your Android projects, please follow the Maven + Eclipse instructions instead.

Configuring Eclipse

Do the following to use AndroidAnnotations within the Eclipse IDE:

  1. Right-click your project, choose "Properties"
  2. Go to Java Compiler and make sure that "Compiler compliance level" is set to "1.6", otherwise the processor won't be activated
  3. Go to Java Compiler > Annotation Processing and choose "Enable annotation processing"
  4. Go to Java Compiler > Annotation Processing > Factory Path and add the processor JAR : androidannotations-X.X.X.jar
  5. Go to Java Build Path > Libraries and add the API JAR : androidannotations-X.X.X-api.jar
  6. Confirm the workspace rebuild
  7. You can start using AndroidAnnotations and you should now see any annotation problems as regular error markers within the editor and in the Problem view.

This documentation is highly inspired (not to say c&p) from the Hibernate Validation Annotation Processor Documentation. If you do not use Eclipse, you will find it quite helpful.

Wiki

Using AndroidAnnotations

Questions?

Developing AndroidAnnotations

Misc

Clone this wiki locally