androidannotations usage

androidannotations usage tips:

{1} Configuring Eclipse

  1. Put androidannotations-X.X.X-api.jar in the libs folder
  2. Put androidannotations-X.X.X.jar in a different folder, such as compile-libsandroidannotations-X.X.X.jar must not go in the libs folder.
  3. Right-click on your project, choose "Properties"
  4. Go to Java Compiler and make sure that Compiler compliance level is set to 1.6, otherwise the processor won't be activated
  5. Go to Java Compiler > Annotation Processing and choose Enable annotation processing
  6. Go to Java Compiler > Annotation Processing > Factory Path and add the processor JAR : androidannotations-X.X.X.jar.
  7. Confirm the workspace rebuild
  8. Go to Java Build Path > Libraries and add the API JAR : androidannotations-X.X.X-api.jar, unless it's already in the build path (ADT 17 automatically adds JARs that are in the libs folder).

{2} error fix:

         1."Type Conversion to Dalvik format failed: Unable to execute dex: Multiple dex files define Lorg/androidannotations/annotations/AfterInject;"           resolution

猜你喜欢

转载自jonson.iteye.com/blog/2038977