Dynamic objects in the DLR provide a foundation that has many applications. In previous chapters, we’ve seen some practical examples that leverage this foundation and do interesting things that are either awkward or impossible in static languages. In this chapter, we are going to travel further down the path and see the fantastic application of dynamic objects in aspect-oriented programming (AOP). AOP is a programming paradigm that is very good at solving the problem of cross-cutting concerns. Common cross-cutting concerns in a software system are issues like transaction management, security, auditing, performance monitoring, logging and tracing, and so on. By virtue of addressing the problem of cross-cutting concerns in an elegant manner, AOP provides tremendous value in the design and architecture of software systems. I’ll begin with an introduction of the basic AOP concepts accompanied by some simple examples, then show you how to implement an AOP framework based on dynamic objects. By the end of the chapter, you will have an AOP framework that (a) works across both static and dynamic objects and (b) is integrated with the widely adopted Spring.NET’s AOP framework.
KeywordsDynamic Object Application Context Customer Class Public Class Advice Class
Unable to display preview. Download preview PDF.