Latest news and articles about DDD, CQRS, Event Sourcing and Software Architecture in general, aggregated daily and delivered weekly to your feed (RSS) reader. Subscribe here!

Week 32, year 2014

  • Resolving Feature Envy in the Domain - Benjamin Eberlei did a really nice job of explaining refactoring the Feature Envy code smell on his blog. I wrote a comment because I felt the example could be taken one step further. You should read the original post. Below are Benjamin’s code examples (for reference), followed by a repost of my comment. Original examples <?phpfunctioncalculateReport(DateTime$start,$days){if($days<0){thrownewInvalidArgumentException($days);}$endDate=clone$start;$endDate->modify('+'. $days. [Mathias Verraes]
Permalink | From 04 August 2014 to 10 August 2014 | Last updated on: Mon, 7 Jun 2021 09:18:52 GMT