/RefactoringBookExamples

This repository contains my exercises when reading Martin Fowler's Refactoring Book

Primary LanguageC#MIT LicenseMIT

Martin Fowler's Refactoring Book Exercises

This repository contains my exercises when reading Martin Fowler's book:

Refactoring: Improving the Design of Existing Code, 1st Edition

All examples are in C# 10, .NET 6.0 (translated from original Java in the book)

  • Note: Before and After are source code examples from Martin Fowler's book, Final are my improvements and interpretations.

Chapter 9: Simplifying Conditional Expressions

07. Introduce Null Object

(Page: 260)

You have repeated checks for a null value. Replace the null value with a null object.
See: Before | After | Final

In Refactoring, 2nd edition this refactoring technique is listed as: Introduce Special Case


Refactoring, 2nd edition, Online catalog