[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [aspectj-users] Help in Eclipse + AspectJ using AJDT

Thanks Andy for the help.

>> When I use inpath of aspect project, I do see some .class files
copied 
>> to the aspect project. But I do not see any markers on the aspect
file.
>> Also, the files that are copied/woven are not actual calsses that I 
>> adviced but the other classes that use this class. When I advice on
'execution method()'
>> pointcut I expected the class that I advice should be modified, is it
not correct?

>You may not see markers when weaving this way - I would say test the
woven application and see if it does what 
>you want it to do (although I see you can't run it for some reason).
All the classes go through the weaving 
>process and will end up in the output folder of the AspectJ project,
not just those your aspect is choosing with 
>its pointcuts.  The aspectj project is then considered to contain your
entire woven application and you should 
>use the contents of it when running your code, not the code from the
plain java project.

   For some reason I only see a handful of classes there and not the one
   I need. Something may be missing. But I am able to use the second
method
   described below.  You are correct that the dvice markers do not seem
to
   be correct all the time. I now see advice markers on the target class
file
   but in the aspect file it says advice not applied. That is ok.

>That is correct, the warning will appear against the aspect in the
aspectj project saying, the warning is really >saying "I am not applying
to any code in this project" - which is true.  It doesn't take into
account that you >
>are using it as input to another project.
>Sounds to me like your code is woven, you just need to run it.

   I am not able to run with this method. To make it work I have added
the project
   dependncies and libraries in Java Build Path and I finally got it
working.
   But in the process looks like I have created some circular dependency
between the
   two projects. Ecplise keeps endlessly rebuilding both these projects.
   I have to cleanup the dependencies. 

>There is a UI option to show weaving messages, I cant remember where -
that should produce output if any weaving >is performed.

   This will be useful. I will check it out.

Thanks again everyone for the help.

Srini