Basic Design PrinciplesFor What the Alarm Bell Should RingRigid, Therefore FragileEasier to Use Than to ReuseEasier to Work Around Than to FixStructured DesignFrom Spaghetti Code to Lasagna CodeCohesionCouplingSeparation of ConcernsIdentifying the ConcernsModularityInformation HidingSoC and Programming ParadigmsObject-Oriented DesignBasic OOD PrinciplesFind Pertinent Objects FirstFavor Low CouplingFavor Code ReuseAdvanced PrinciplesThe Open/Closed PrincipleLiskov’s Substitution PrincipleThe Dependency Inversion PrincipleFrom Principles to PatternsWhat’s a Pattern, Anyway?Design PatternsHow to Work with Design PatternsWhere’s the Value in Patterns, Exactly?Applied Design PatternsArchitectural PatternsPatterns vs. IdiomsWhat’s an Idiom, Anyway?Sample IdiomsIdiomatic DesignIdiomatic Design: Structures or Classes?Idiomatic Design: Do Not Use List<T> in Public SignaturesDependency InjectionFrom DIP to Inversion of ControlIoC FrameworksIoC Containers in ActionApplying Requirements by DesignTestabilitySoftware TestingSoftware ContractsUnit TestingUnit Testing in ActionDealing with DependenciesFrom Fakes to MocksSecuritySecurity as a (Strict) RequirementSecurity Development LifecycleFoundations of SDL: LayeringFoundations of SDL: ComponentizationFoundation of SDL: RolesThreat ModelSecurity and the ArchitectFinal Security PushFrom Objects to AspectsAspect-Oriented ProgrammingCross-Cutting ConcernsProcessing AspectsInside AOP AspectsAOP in .NETAOP in ActionEnabling PoliciesDefining PoliciesDefining HandlersSummaryMurphy’s Laws of the Chapter