aspose file tools
The moose likes Java in General and the fly likes AspectJ MethodSignature Returns Null Method Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » Java in General
Reply Bookmark "AspectJ MethodSignature Returns Null Method" Watch "AspectJ MethodSignature Returns Null Method" New topic
Author

AspectJ MethodSignature Returns Null Method

Jeff Storey
Ranch Hand

Joined: Apr 07, 2007
Posts: 230
Hi. I'm relatively new to AspectJ (used in the past, but not for a while, so I'm a little bit rusty). I've setup a pointcut to catch all method calls, which it does, and then in the advice, I'm trying to print out the actual method that was called. I can do that using the following: thisJoinPoint.getSignature().toString() and that works just fine. However, I'm trying to get the underlying Method object, with thisJoinPoint.getSignature().getMethod(), and the method sometimes returns null when the signature is not null. Can anyone explain why this is happening?

Thanks,
Jeff
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: AspectJ MethodSignature Returns Null Method
 
Similar Threads
AspectJ: catch and handle exception using aspectJ
Debugging in Java
AspectJ question
Method invocation _after_ ending of another method
AspectJ MethodSignature Returns Null Method