Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » AJDT » get the value of an attribute inside an advice
get the value of an attribute inside an advice [message #669697] Wed, 11 May 2011 08:11
moha  is currently offline moha Friend
Messages: 43
Registered: March 2011
Member
Hi,

i want to get the value of attribute defined in the class below
using aspectj:

public class Test {

public String attribute = "string";

public void myMethod (){

.....


}
}

i developped an aspect using aspectj annotation :

@Aspect
public class TestAspect {
@Pointcut("execution(* *.Test.myMethod(..))")
public void myPointcut() {

}

@Before("myPointcut()")
public void myAdvice(JoinPoint joinPoint){

//how can i use joinPoint to get the value of attribute in Test class
}

}
Question : how can i use joinPoint to get the value of attribute in Test class ????

thanks;
Previous Topic:Servlet Run on Server asks if I want to save file???
Next Topic:push in refactoring fails
Goto Forum:
  


Current Time: Fri Dec 15 00:34:56 GMT 2017

Powered by FUDForum. Page generated in 0.01294 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software