Fewer lines of code
- Less code = less development time
- Less code = fewer bugs
- Less code to read = easier maintenance
- Better separation of concerns
- Reduce code scattering Code scattering: the fact that a feature is implemented into a large number of code artefacts, for instance classes or methods. Highly scattered features are proved to be more difficult to maintain.
- Reduce code tangling Code tangling: the fact that a code artefact (for instance a class or a method) contains the implementation of several features. Code exhibiting high code tangling is more difficult to understand.
- Reduce coupling Coupling: the fact that a component depends on another component. The more assumptions a component makes about its neightboors, the more coupling. Strongly-coupled architectures are more difficult to maintain because a change in one component may affect many components.
Better division of labor
- Separate business code from infrastructure code.
- Reduce requirements on skills and knowledge of new project members.
- Improve ability of senior developers to encapsulate their knowledge into reusable components.
- Allow for better specialization of individuals in the team.
AOP: White Paper
Details the benefits of Aspect-Oriented Programming, and illustrates how two companies successfully implemented AOP: Siemens Healthcare using AspectJ™, and FullArmor using PostSharp.
Build automation for your own patterns
PostSharp Aspect Framework
Build and inject custom design patterns into your .NET apps
- Intercept methods, properties, fields
- Intercept events pro
- Introduce methods, events, properties, interfaces pro
- Add custom attributes, managed resources pro
- Apply aspects using multicast custom attributes
- Apply aspects using multicast XML file and dynamic provider pro
- Robustly compose aspects pro
- Support for .NET Framework 2.0-4.5
- Support for Windows Phone, Silverlight, Windows Store pro
PostSharp Architecture Framework
Enforce good design
- Restrict Interface Implementation
- Control Visibility
- Restrict Access
- Custom Constraints
- Extented Reflection API
- Decompile to syntax tree
PostSharp Pattern Libraries
Ready-made implementations of the most frequent patterns
PostSharp Model Pattern Library
Simplify UI and model layers
- Code Contracts
PostSharp Diagnostics Pattern Library
Add uninstrusive code instrumentation
- NLog, Log4Net, Enterprise Library
PostSharp Threading Pattern Library
Simplify multithreaded programming
- Thread Dispatching (UI/Background)
- R/W Synchronized Threading Model
- Actor Threading Model
- Exclusive Threading Model
- Deadlock Detection