SketchDDD
A Categorical Framework for Domain-Driven Design.
Build precise domain models visually or with code.
Overview
SketchDDD bridges the gap between domain experts and developers by providing precise mathematical definitions for DDD concepts using category theory.
| DDD Concept | Mathematical Definition |
|---|---|
| Bounded Context | Sketch (graph + equations + limits) |
| Aggregate | Limit cone with root |
| Value Object | Limit with structural equality |
| Context Map | Sketch morphism |
Installation
[]
= "0.1"
Quick Start
use *;
// Create a bounded context
let mut ctx = new;
// Add entities
let customer = ctx.add_entity;
let order = ctx.add_entity;
// Add value objects
let money = ctx.add_value_object;
// Add enumerations
let status = ctx.add_enum;
Crates
sketchddd- This crate (facade)sketchddd-core- Core data structuressketchddd-parser- DSL parsersketchddd-codegen- Code generationsketchddd-viz- Visualizationsketchddd-cli- Command-line tool
License
Licensed under either of MIT or Apache-2.0 at your option.