Hi all,
Nice to meet everyone here!
I'm new to Android and wanted to use AspectJ with it. I had searched couple articles online and follow the instruction to have it working: http://blog.punegtug.org/2010/11/adding-aspect-to-android.html
But I wanted to know whether if it's possible to separate the aspects away from the Android project. In the tutorial link above, it has both the Android App and the aspects inside the same project, but in many cases, we wanted to leave the Android Project untouched in its isolating spaces.
Let said I have AndroidProject in my Eclipse workspace, I would like to create a separate projects for my aspects called something like "AndroidAspectProject" which only contains the aspects for it.
I'm not sure whether this would work because it seems we need to let AspectJ compiler inject point cuts and advices to the .class files before creating the .dex files. In this sense, I may not able to do it in a separate project.
Does anyone try with this?
Another related question would be: Is it possible to have Ant build the AndroidProject with AND without aspects on it? Can this be done outside of Eclipse?
I'm looking for a way to build different flavours as I'm only injecting pointcuts into the AndroidProject on dev/debug build, but will leave it untouched on release build.
I had already asked such question on Stackoverflow: http://stackoverflow.com/questions/8409425/android-with-aspectj-and-building-it-with-ant-on-eclipse
But I’m still stuck to finding the best way to handle my case of building AspectJ libraries used in Android Project.
Andrew Eisenberg (thanks to him, the person who recommended me using this mailing list) already provided some advices to my question, however, it doesn’t really quite working for me as I had errors when I put my *.aj as a separate projects in the workspace in Eclipse.
Thanks in advanced for any answers for this!
Thanks.
Sam Xiao.
Office: 1-408-324-3760