Introduction
As you know AOP is one of the best features provided by Spring framework which provides utmost flexibility while achieving cross cutting concerns. Have you thought of how AOP works in Spring ? Sometimes this is the question asked in case of senior level technical interview. Sometimes this question becomes more significant when it comes to only core java. Recently one of my friend went to attend the interview and he faced an embarrassing question about how to use AOP only in core java without using Spring and related libraries. In this article I will provide you an outline about how to create your own AOP only in core java of course with certain limitations. This is not a comparative study between Spring AOP and Java AOP. However you can achieve AOP in java to certain extent using proper design patterns.
Debadatta MishraMarch 4th, 2015Last Updated: March 2nd, 2015

This site uses Akismet to reduce spam. Learn how your comment data is processed.
If you have an interface and implementation, you can simply apply the decorator pattern to the same effect, without the need for proxies and reflection.
You are correct Tom, we can also achieve using Decorator Pattern, I have written a template being inspired by Spring AOP template formatting.
Simply great Deba