Search code examples
javaandroidspringaspectjspring-roo

aspectj and spring roo 'NoAspectBoundException'


I have a api.jar with some entities compiled with Spring Roo. I use this library from my android application and see following for every roo generated entity:

E/dalvikvm(10938): Could not find class 'org.aspectj.lang.NoAspectBoundException', referenced from method _Roo_Json.aspectOf W/dalvikvm(10938): VFY: unable to resolve new-instance 2010 (Lorg/aspectj/lang/NoAspectBoundException;) in L_Roo_Json;

I searched at stackoverflow and found only one answer and it didn't help (suggested to add a aspectjrt).

Does anybody has a clue what does it means?


Solution

  • As Spring-Roo uses AspctJ ITD to generate code you need add its runtime libraries as a dependency. But I think that AspectJ is not suitable for Android. It works

    I found android-aspectj library which seems to be a possible way to archive this (I don't try it). Also, this library refers to a post which explains it.

    Good luck!