Category Archives: Domain-Driven Design

Aggregated specifications

An example from my inversion of control talk involves a message formatter.  It applies formatting rules to a string. public interface IMessageFomatter { string Format(string message); } Instead of doing all the work in the implementation of this interface, the … Continue reading

Posted in C#, Domain-Driven Design | 7 Comments

More On Value Objects

A few days ago Dylan Beattie wrote a nice post about value objects.  He explains the idea in a more palatable way than my attempt: If it’s not clear how to model a particular element in your model, try asking … Continue reading

Posted in Domain-Driven Design | Tagged , , | 1 Comment

There is never a collection of Value Objects

Adding to a Value Object property always adds to it, never adds another instance to it.  Distinguishing Value Objects by maintaining a collection of them implies identity. It is a mistake to attempt to maintain a collection of Value Objects. … Continue reading

Posted in Domain-Driven Design | Tagged , , | 15 Comments