DDD – tactical design
Tactical design focuses on the internal model and relationships within a bounded context. It aims to create a highly cohesive domain model that expresses the essential business concepts and aligns with the ubiquitous language that’s used within the context.
Tactical design consists of several building blocks that provide a foundation for designing and building a bounded context within complex business domains:
- Value objects: These represent concepts without an identity. They’re immutable and defined by their attributes rather than their identity. Value objects are used to model concepts considered as a unit. They’re used for their attributes and can be shared and compared by value. The following
Address
class is a value object as it has no identity but encapsulates multiple fields that form an address:data class Address( val line1: String, val line2: String? = null, &...