Archive

The 'Week of PostSharp' is a joint promotion with Manning Publications where we highlight a new book each day that is special to us and hand-picked by the PostSharp team – with a small introduction about how it connects to what we are doing. We also collaborated with Manning to select a second book for each day of the week, and will be offering our choices at a 50% discount on their site! You can even read excerpts from some of the books online for free by clicking on the links below.

We hope you enjoy the deals! We’ll be adding new posts with the daily discount code throughout the week, so stay tuned.

Design patterns are now universally accepted and have significantly improved the way we design software. However, they had relatively little impact on how we implement it. Except rare exceptions like the ‘using’ or ‘lock’ keywords, most patterns must still be implemented by hand, resulting in large quantities of boilerplate code that must be validated by peer review. However, smarter compilers and development tools could do a better job by automatically implementing part of the pattern and automatically validating the part that was implemented manually. We call this design pattern automation. At PostSharp Technologies, we believe that design pattern automation, as it raises the abstraction level of source code, will make it easier to build good software.

If Design Pattern Automation is the objective, meta-programming and aspect-oriented programming are the tools. Meta-programming refers to the ability to alter a program either at build- or run-time. Aspect-oriented programming (AOP) is a paradigm that allows to add features to existing code without directly editing this code. Although AOP is not purely meta-programming, these concepts largely blend together. PostSharp, for instance, relies on AOP to alter applications but on meta-programming to select elements of code that must be altered.

Developers like technical quarrels, and meta-programming has been no exception. At PostSharp, we believe that a technology is good if it makes it easier to write good software – for an average development team. It does not help if the best developers are getting a little productivity gain whereas the rest of the team pains at understanding the code. While doing meta-programming, we should be obsessed by this question: did I make it easier for my team to write good software?

Today, we're recommending the following books that you can buy with a 50% discount until August 23rd, 12 midnight EST:

 

Metaprogramming in .NET is a practical introduction to the use of metaprogramming to improve the performance and maintainability of your code. This book avoids abstract theory and instead teaches you solid practices you'll find useful immediately. It introduces core concepts like code generation and application composition in clear, easy-to-follow language, and then it takes you on a deep dive into the tools and techniques that will help you implement them in your .NET applications.

Download Free Chapter (PDF)   |   Purchase with 50% discount using the code pswkd4

 

DSLs in Boo shows you how to design, extend, and evolve DSLs for .NET by focusing on approaches and patterns. You learn to define an app in terms that match the domain, and to use Boo to build DSLs that generate efficient executables. And you won't deal with the awkward XML-laden syntax many DSLs require. The book concentrates on writing internal (textual) DSLs that allow easy extensibility of the application and framework. And if you don't know Boo, don't worry—you'll learn right here all the techniques you need.

Download Free Chapter (PDF)   |   Purchase with 50% discount using the code pswkd4

 

 

The 'Week of PostSharp' is a joint promotion with Manning Publications where we highlight a new book each day that is special to us and hand-picked by the PostSharp team – with a small introduction about how it connects to what we are doing. We also collaborated with Manning to select a second book for each day of the week, and will be offering our choices at a 50% discount on their site! You can even read excerpts from some of the books online for free by clicking on the links below.

We hope you enjoy the deals! We’ll be adding new posts with the daily discount code throughout the week, so stay tuned.

I guess there’s a strange secret affair between Microsoft and Aspect-Oriented Programming. Never, ever has Microsoft used the word Aspect-Oriented Programming in its products. Yet, many products implement some of these concepts:

  • ASP.NET MVC (filters)
  • ASP.NET (modules)
  • WCF (custom behaviors)
  • Unity (interceptors)
  • Policy Injection Application Block (policy)
  • Base Class Library (transparent proxy, ContextBoundObject)

Thinking twice, it’s fair enough that Microsoft never called that aspect-oriented programming. After all, with the exception of ASP.NET MVC, these are quite purpose-specific implementations of one or two design patterns: pipes-and-filters, or proxies. But with ASP.NET MVC, they got pretty close.

Get convinced yourself with the books of the day which you can now purchase with a 50% discount - but hurry, the offering is valid only until August 22th, 12 midnight EST:

 

ASP.NET MVC 4 in Action is a hands-on guide that shows you how to apply ASP.NET MVC effectively. After a high-speed ramp up, this thoroughly revised new edition explores each key topic with a self-contained example so you can jump right to the parts you need. Based on thousands of hours of real-world experience, the authors show you valuable high-end techniques you won't find anywhere else. Written for developers, the book arms you with the next-level skills and practical guidance to create compelling web applications. You need some knowledge of ASP.NET and C#, but no prior ASP.NET MVC experience is assumed.

Download Free Chapter (PDF)   |   Purchase with 50% discount using the following discount code: pswkd3

 

ASP.NET in Practice distills over 100 practical ASP.NET techniques from the experience of a team of MVPs, and puts them right at your fingertips. The techniques are tested and selected for their usefulness, and they are all presented in a simple problem-solution-discussion format. You'll discover methods for key new subjects like data integration with Entity Framework and ASP.NET MVC. Along the way, you'll also find ways to make your applications fast and secure.

Download Free Chapter (PDF)   |   Purchase with 50% discount using the following discount code: pswkd3

 

The 'Week of PostSharp' is a joint promotion with Manning Publications where we highlight a new book each day that is special to us and hand-picked by the PostSharp team – with a small introduction about how it connects to what we are doing. We also collaborated with Manning to select a second book for each day of the week, and will be offering our choices at a 50% discount on their site! You can even read excerpts from some of the books online for free by clicking on the links below.

We hope you enjoy the deals! We’ll be adding new posts with the daily discount code throughout the week, so stay tuned.

There are times when OOP won’t let us achieve a nice separation of concerns (assembly > namespace > class > method). Think of INotifyPropertyChanged, logging, performance monitoring, transaction handling, undo/redo, caching… Way too often, we have to duplicate tons of infrastructure code. This is why aspect-oriented programming (AOP) has been engineered. With AOP, you can encapsulate cross-cutting features into a special class called an aspect, and apply the aspect to a large number of classes or methods without actually modifying your business source code. As a result, you get rid of most of your boilerplate.

PostSharp has long been the most complete and the most popular AOP framework for .NET but PostSharp is not limited to AOP, and AOP is not limited to .NET. Today we’re recommending two books: AOP in .NET, which gives you an excellent introduction to AOP not only using PostSharp, and AspectJ in Action, whose outstanding quality makes it a must-read for anyone interested in aspect-oriented programming and offers deep insights that are directly applicable to PostSharp. You can now purchase these books with a 50% discount using the discount code pswkd2! But hurry, the offering is only valid until August 21st 12 midnight EST!

AOP in .NET introduces aspect-oriented programming and provides guidance on how to get the most practical benefit from this technique. The book's many examples concentrate on modularizing non-functional requirements that often sprawl throughout object-oriented projects. You'll appreciate its straightforward introduction using familiar C#-based examples.

Download Free Chapter (PDF)   |   Purchase with 50% discount using the discount code pswkd2

 

AspectJ in Action, Second Edition is a fully updated, major revision of Ramnivas Laddad's best-selling first edition. It's a hands-on guide for Java developers. After introducing the core principles of AOP, it shows you how to create reusable solutions using AspectJ 6 and Spring 3. You'll master key features including annotation-based syntax, load-time weaver, annotation-based crosscutting, and Spring-AspectJ integration. Building on familiar technologies such as JDBC, Hibernate, JPA, Spring Security, Spring MVC, and Swing, you'll apply AOP to common problems encountered in enterprise applications.

Download Free Chapter (PDF)   |   Purchase with 50% discount using the code pswkd2