Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [aspectj-users] local variables in methods

>Diana,
>
>AspectJ does not support the non-local declaration of local 
>variables, for various good (in my opinion) reasons having
>to do with program robustness.
>
>If you're actually trying to solve a programming problem (as
>opposed to an exercise) then it may be the case that you don't
>really need to have non-local local variables -- a few times
>users have asked for this kind of thing they really wanted 
>around advice.  You might have better luck if you wrote a concise
>message to this newsgroup explaining what you're trying to do.
>
> -erik


    I need to define one advice that is executed before every method execution 
and one advice that is executed when certain statements inside that method are 
executed. 
    The first type of advice is used to initialize the local variables that I am 
talking about. The second type of advice has to use those variables.
    As I see it, the two advices cannot be replaced by an around advice.

		Thanks again,
		   Diana.
		   
>-----Original Message-----
>From: Diana Szentivanyi [mailto:diasz@xxxxxxxxxx] 
>Sent: Sunday, 4 May, 2003 11:47 pm
>To: aspectj-users@xxxxxxxxxxx
>Subject: [aspectj-users] local variables in methods
>
>
>			Hello!
>			
>     I am working with AspectJ to define some aspect, and I need to introduce 
>variables local to a method. 
>     I know about "Introduction" in AspectJ, but that, as I understood, applies 
>only to introduce methods or variables in a class.
>     
>          I appreciate any help,
>              Regards,
>                Diana.
>_______________________________________________
>aspectj-users mailing list
>aspectj-users@xxxxxxxxxxx
>http://dev.eclipse.org/mailman/listinfo/aspectj-users

-------------------------------------------------------------
Diana Szentivanyi, Dept. of Computer and Inf. Science (IDA)
Linköping Universitet
Tel: +46 13 282416 E-mail: diasz@xxxxxxxxxx



Back to the top