Articles, Home

Dynamic Proxies in Java Mini-Book

In this book we show how we would write a proxy implementation by hand. We then show how we can do the same code using dynamic proxies, saving ourselves a lot of unnecessary code. Since the patterns proxy, decorator, composite and adapter are similar in structure, we can use dynamic proxies to also generate these. Lastly we show how we could use code generation to create the classes in-memory.