What is an aspect in AOP?
An aspect in aspect-oriented programming may be defined as the modularization of a concern. In OOP, you achieve modularity by taking advantage of classes. In AOP, you achieve modularity by taking advantage of aspects. An aspect might be logging or authentication, for example. In AOP, the goal would be to handle all logging or authentication for your application in one place.
The essence of AOP is encapsulating functionalities that are common while at the same time enabling your application to leverage those functionalities as need be. Such common functionalities or cross-cutting concerns include logging, authentication, notifications, transaction management, exception management, etc. Popular AOP frameworks for .NET and C# include Castle Windsor, Microsoft Unity, Policy Injection Block, and PostSharp.
Key concepts of AOP
When working with AOP, you should be familiar with some of the key concepts of the paradigm. These include the following: