如果不使用 FQPN 而是使用类的导入语句,则使用 Maven (3.0.3) 处理 AndroidAnnotations 失败:
这失败了:
请注意在代码中使用导入与 FQPN 的区别,以引用 App 类,在我的例子中是“delta”。
import com.my_project.delta.android.Delta_;
/**
* Splash screen with logo.
*/
@EActivity(R.layout.act_splash)
public class Splash extends BaseActivity {
/**
* Reference to application.
*/
@App
protected Delta_ delta;
虽然这很好用:
/**
* Splash screen with logo.
*/
@EActivity(R.layout.act_splash)
public class Splash extends BaseActivity {
/**
* Reference to application.
*/
@App
protected com.my_project.delta.android.Delta_ delta;
错误如下:
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.0:compile (default-compile) on project com.my_project.delta.android: Compilation failure
[ERROR] /Users/user/Projects/My-Project/delta-android/target/generated-sources/annotations/com/my_project/delta/android/activity/Splash_.java:[29,19] cannot find symbol
[ERROR] symbol: class Delta_
[ERROR] location: class com.my_project.delta.android.activity.Splash_
[ERROR] -> [Help 1]
pom.xml: http: //pastebin.com/HhxCVYmN
AndroidAnnotations 中的错误可能吗?