[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [aspectj-dev] pointcut problem
|
There is no target of a constructor call; it's not created at call time.
But there is a return value for the constructor-call join point; see
http://dev.eclipse.org/viewcvs/indextech.cgi/%7Echeckout%7E/aspectj-home/doc/faq.html#q:adviseconstructors
Wes
zl1979@xxxxxxx wrote:
>
> I defined a pointcut like this:
> pointcut create(Stack s):call(Stack.new())&&target(s);
>
> The code means I want to handle the Stack instantiation event and get this object. But I found this pointcut never arrived in the run process of program.
>
> On the contrary, I define a pointcut like this:
> pointcut create():call(Stack.new());
> At this time, this pointcut is valid.
>
> What's wrong with the first pointcut? How to handle the instantiation event and get the correlative object?
>
> ==========================
> 263µç×ÓÓʼþ£ÐÅÀµÓÊ×ÔרҵjÊ^rØÝzùX§X¬µ«)yËcuëÞrX©±ê+m§ÿÝz÷*lzàþf¢f§þX¬¶)ߣö¬¥ç-ׯ