aspose file tools
The moose likes Other Application Frameworks and the fly likes AspectJ problem with subtype-superType Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCA Java SE 8 Programmer I Study Guide 1Z0-808 this week in the OCAJP forum!
JavaRanch » Java Forums » Frameworks » Other Application Frameworks
Bookmark "AspectJ problem with subtype-superType" Watch "AspectJ problem with subtype-superType" New topic

AspectJ problem with subtype-superType

Kartik Patel
Ranch Hand

Joined: Sep 12, 2005
Posts: 73
I have classes,
class Foo{
public void A(int c,int d) throws Exception

class Bar extends Foo{
public static void main(String args[])
Bar b=new Bar();

I want to put before pointcut on method A. I am using loadtime weaving so binding to perticular class happens from aop.xml

my pointcut is defined something like this
public abstract aspect point();
before(Bar bar,int i1,int i2):execution(public void A(int c,int d) throws Exception) && this(bar) {
//Do something

aop.xml looks like
<pointcut name="point"

Somehow its not working.. Can anyone please help ? Its real urgent.

Chop your own wood, and it will warm you twice. - Henry Ford
Kartik Patel
Ranch Hand

Joined: Sep 12, 2005
Posts: 73
Anyone Please???
Rob Spoor

Joined: Oct 27, 2005
Posts: 19844

Patience Is A Virtue. Surely you can't expect a board of volunteers to reply to each and every post in an hour?

That said, AspectJ is not as widely used as something like Swing, and therefore people with knowledge about it are a bit harder to find. My own experience has lasted about a month back in 2003.

How To Ask Questions How To Answer Questions
Martijn Verburg

Joined: Jun 24, 2003
Posts: 3274

Move to Application Frameworks, hopefully a Spring experienced person can assist (Spring has Aspect J all over it )

Cheers, Martijn - Blog,
Twitter, PCGen, Ikasan, My The Well-Grounded Java Developer book!,
My start-up.
I agree. Here's the link:
subject: AspectJ problem with subtype-superType