Posts

Showing posts from July, 2013

Aspect's Paradigm With Design Patterns (Proxy Pattern)

Implementation of Design patterns with AspectJ is another intersting episode of AspectJ. After I have implemented a few such Design patterns, I came to realize the power of AspectJ and How beautiful it is. So,I will share my expereince with this dimension of AspectJ Proxy Pattren First, I have created some Utility classes which will be assigned some role using Aspects Dynamically. package com.aspectj.target; import java.io.IOException; import javax.naming.OperationNotSupportedException; public class PureSubject { public String write() { System.out.println(" @@@ In PureSubject.write() @@@ "); return "### PureSubject.write() completed ###"; } public String read() throws OperationNotSupportedException { throw new OperationNotSupportedException("This Operation is not Supported in this version"); } public String update() throws OperationNotSupportedException { throw new OperationNotSupportedException("This Operatio