11 Tool-based Aspect-Oriented Programming

In this chapter

  • Using dynamic Interception to apply Interceptors using generated Decorators
  • Advantages and disadvantages of dynamic Interception
  • Using compile-time weaving to apply Cross-Cutting Concerns
  • Why compile-time weaving is the antithesis of DI

This chapter is a continuation of the Aspect-Oriented Programming (AOP) discussion that we started in chapter 10. Where chapter 10 described AOP in its purest form — namely, applying AOP solely using SOLID design practices — this chapter approaches AOP from a tool-based perspective. We’ll discuss two common methods for applying AOP: dynamic Interception and compile-time weaving.

In case the design approach of chapter 10 is too radical, dynamic Interception ...

Get Dependency Injection Principles, Practices, and Patterns now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.