Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/1-terms/A/term-aggregate.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

==== Aggregate

Aggregate is a building block of <<term-DDD,Domain-Driven Design>>. Aggregates are complex object structures that are made of <<term-entity,entities>> and <<term-value-object,value objects>>. Each aggregate has a root entity and is regarded as one unit when it comes to changes. An aggregate ensure consistency and integrity of its contained entities with invariants.
Aggregate is a building block of <<term-DDD,Domain-Driven Design>>. Aggregates are complex object structures that are made of <<term-entity,entities>> and <<term-value-object,value objects>>. Each aggregate has a root entity and is regarded as one unit when it comes to changes. An aggregate ensure consistency and integrity of its contained entities with <<term-invariant,invariants>>.



Expand All @@ -18,7 +18,7 @@ Ein Aggregat ist ein Baustein des <<term-DDD,Domain-Driven Designs>>. Aggregate
aus <<term-entity,Entitäten>> und <<term-value-object,Wertobjekten>>
bestehen. Jedes Aggregat hat eine Root-Entität und wird in Bezug auf
Änderungen als Einheit betrachtet. Aggregate stellen die Konsistenz
und Integrität ihrer enthaltenen Entitäten mit Invarianten sicher.
und Integrität ihrer enthaltenen Entitäten mit <<term-invariant,Invarianten>> sicher.


// end::DE[]
23 changes: 23 additions & 0 deletions docs/1-terms/I/term-invariant.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
[#term-invariant]

// tag::EN[]
==== Invariant

A condition or property that must always remain true throughout the lifetime of a system, component, or object, regardless of which operations are performed.
Invariants represent guarantees about system state that are actively maintained and protected by <<term-make-illegal-states-unrepresentable,making illegal states unrepresentable>> or by actively preventing state transitions that would violate the invariant.

They differ from validations in their scope and enforcement: while validations check whether data meets certain criteria (at input boundaries or elsewhere), invariants are structural guarantees that prevent the system from ever reaching invalid states.
Algebraic data types, especially <<term-sum,sum types>> and <<term-product,product types>>, help enforce invariants at design- and compile-time rather than runtime.

// end::EN[]

// tag::DE[]
==== Invariante

Eine Bedingung oder Eigenschaft, die während der gesamten Lebensdauer eines Systems, einer Komponente oder eines Objekts immer wahr bleiben muss, unabhängig davon, welche Operationen ausgeführt werden.
Invarianten stellen Garantien über den Systemzustand dar, die aktiv aufrechterhalten und geschützt werden, indem sie <<term-make-illegal-states-unrepresentable,illegale Zustände nicht darstellbar machen>> oder aktiv Zustandsübergänge verhindern, welche die Invariante verletzen würden.

Sie unterscheiden sich von Validierungen in ihrem Geltungsbereich und ihrer Durchsetzung: Während Validierungen prüfen, ob Daten bestimmte Kriterien erfüllen (an Input-Grenzen oder anderswo), sind Invarianten strukturelle Garantien, die verhindern, dass das System jemals ungültige Zustände erreicht.
Algebraische Datentypen, insbesondere <<term-sum,Summentypen>> und <<term-product,Produkttypen>>, helfen dabei, Invarianten zur Design- und Compile-Zeit statt zur Laufzeit durchzusetzen.

// end::DE[]
Loading
Loading