Difference between @target and @within in Spring AOP
Hi
I was just wondering, if there is a difference and if yes where the difference is between @target(annotation) and @within(annotation) when using Spring AOP.
From the Spring reference manual:
any join point (method execution only in Spring AOP) where the target object has an @Transactional annotation:
@target(org.springframework.transaction.annotation .Transactional)
any join point (method execution only in Spring AOP) where the declared type of the target object has an @Transactional annotation:
@within(org.springframework.transaction.annotation .Transactional)
Guido Schmutz
Principal Consultant, Trivadis Switzerland
Email: guido.schmutz AT trivadis.com