[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aspectj-users] Constructor pointcut

Here is how you can access a newly created instance:

pointcut newInstance(SomeObject obj) :
   this(obj) &&
   execution(SomeObject.new(..));

I hope this helps.

Val

----- Original Message -----
From: "Carlos Lizarralde" <clizarralde@xxxxxxxxxx>
To: <aspectj-users@xxxxxxxxxxx>
Sent: Monday, December 30, 2002 2:48 PM
Subject: [aspectj-users] Constructor pointcut


> Hi, I am new to Aspect J and I have been trying to declare a point cut in
> a constructor so that I can access the instance that I just created.
> I have tried many things but none of them worked. What I am tring to do
> is to set in an object's attribute the time when It was created.
>
> Thanks ,
>
> Carlos Lizarralde
>
> _______________________________________________
> aspectj-users mailing list
> aspectj-users@xxxxxxxxxxx
> http://dev.eclipse.org/mailman/listinfo/aspectj-users
>