Hello,
I am reading the Spring in Action book and trying to make examples to work.
I made an aspectJ project + spring in STS.
In spring config file:
and the aspect:Code:<bean class="com.aspectj.JudgeAspect" factory-method="aspectOf"> <property name="test" value="true"/> </bean>
Got no error on missing aspectOf method but the breakpoint at setTest never hit and the test is null (when pointcut run). What do I miss?Code:public aspect JudgeAspect { public JudgeAspect() {} pointcut performance() : execution(* perform(..)); after() returning() : performance() { System.out.println(""); } private Boolean test; public Boolean isTest() { return test; } public void setTest(Boolean test) { this.test = test; } }
Thanks in advance.


Reply With Quote
