I have one more doubt... I am adding aspects to hadoop source code and I
imported one of the package and created aspect aj file but while running I
have to choose main function but it seems no class of this package have main
function...What I have to do?...Plz help me...
--
View this message in
can you share a link or any other on how to create a configuration
manually...also is it mandatory to mention the main class in the
configuration?
--
View this message in context:
http://aspectj.2085585.n4.nabble.com/Aspectj-in-weaving-a-jar-file-tp4651584p4651607.html
Sent from the AspectJ -
Hi Andy
Thank u...I have created aspect aj file for a java class file and then I
exported it as a jar file and I imported it in another Aspectj project and
called the function for which the advice had written and it runs normally.
But when I import it in java project, the advice never
A standard java project has no awareness of aspects. You have two options:
- use the context menu on the Java project to add the aspectj nature. This
replaces the java builder for the project with the aspectj builder. You can
then set (in the project properties) the aspect path and point it at
Hi Andy
Thank u for ur reply...After creating a jar file(combining aspectj file and
java file) whether I can import it into a normal java project and If i
refer(calll) any function for which advice is written whether advice runs or
not?
--
View this message in context:
If you create a jar file containing the compiled (by aspectJ) aspectj file
and java file, then if you call methods in the compiled java file in
another project into which you've imported that jar then the advice will
run. They key thing is that AspectJ has to be involved at some point to
weave
I have one more doubt...If I had done compile-time weaving then I export the
aj file and java file as jar and I referred function by running java in
command prompt...Is advice run?
--
View this message in context:
Hi I am new to aspectj. I have a jar in which function named add exists which
calls another function display. I imported it into the aspectj aj file and
wrote pointcut for the function display but it never works. But it works for
the function add. Can any one share their knowledge...
Thanks...
I have to assume it is related to the pointcuts involved. Hopefully you are
doing something like this:
aspect MyAspect {
before(): execution(* add(..)) {
System.out.println(“add() is about to run”);
}
before(): execution(* display(..)) {
System.out.println(“display() is about to