Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aspectj-users] Injecting a component in a non-spring environment

Hello,

I tried to do what you suggest, and came up with the following code:

public aspect BusinessRuleAspectConfigurer 
{
	  before(BusinessRuleAspect obj): execution(BusinessRuleAspect.new(..)) &&
this(obj) {
		     obj.businessRuleManager = BusinessRuleAspect.aspectOf();
	  }
}

There are a few things I still don 't understand (please be patient with me
;-) ):
1) the code doesn't compile because BusinessRuleAspect.aspectOf() produces
something with a type of BusinessRuleAspect, which is not compatible with
the businessRuleManager on the left
2) What mechanism is supposed to create the aspect, when I don't have spring
creating it from the application context? 



--
View this message in context: http://aspectj.2085585.n4.nabble.com/Injecting-a-component-in-a-non-spring-environment-tp4651384p4651388.html
Sent from the AspectJ - users mailing list archive at Nabble.com.


Back to the top