Relationships between entities
Types
Reflexive association
- Same object appears under different roles Arity (N-ary associations)
- Number of linked entities, where >2 is rare and must be distinguished
- Constraints include (optional linking, mandatory linking, uniqueness, etc…) Object specialization/generalization
- Specialization = sub-classing (extending a class for specificity, the parent class generalizes the child class)
- Inheritance is a consequence here
- Can have a discriminator which is an attributes whose values define different specialization Decompositon/aggregation
- An object can belong weakly to several containers or strongly to one
- To distinguish, ask can an object exist without its container?
- Apply composition to aggregates of physical objects or when parts share a lifecycle with the whole Ordered associations
- Denote order OR associations
- Same role can be played by multiple objects Associations of associations
- One of the linked objects is an association
We can represent associations through a tuple of linked objects kind of like a Dependancy Array
Qualifiers
A unique association used at one end to distinguish uniquely identify something on the other end of the association (like a PK)