O'Reilly logo

.NET Design Patterns by Shine Xavier, Praseed Pai

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Finalizing the solution

We started with a solution that solved the problem at hand. After creating a basic pipeline, we created an elaborate pipeline, which made the solution extensible. Now we can add new commands without recompiling the application. This is very important in the case of applications that are governed by amendable laws. To make our code robust, we will add the design by contract strategy to our command objects.

Design by contract and template method pattern

The design by contract idiom, created by Bertrand Meyer (creator of the Eiffel language), extends the ordinary definition of abstract data types with preconditions, post conditions, and invariants. To execute any contract in real life, we need to satisfy some preconditions, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required