| | 1 | ''' |
| | 2 | This module provides support for defining relationships between your Elixir |
| | 3 | entities. The supported relationship types are as follows: |
| | 4 | |
| | 5 | `belongs_to` |
| | 6 | ------------ |
| | 7 | Describes the child's side of a parent-child relationship. For example, |
| | 8 | a `Pet` object may belong to its owner, who is a `Person.` This could be |
| | 9 | expressed like so: |
| | 10 | |
| | 11 | class Pet(Entity): |
| | 12 | belongs_to('owner', of_kind='Person', inverse='pets') |
| | 13 | |
| | 14 | You must specify the 'kind' of object that you are relating to using the |
| | 15 | of_kind keyword argument. Additionally, if you plan on defining the other |
| | 16 | side of the relationship, you should specify the name of the relationship |
| | 17 | on the other side using the 'inverse' keyword argument. |
| | 18 | |
| | 19 | |
| | 20 | `has_one` |
| | 21 | --------- |
| | 22 | TODO. |
| | 23 | |
| | 24 | |
| | 25 | `has_many` |
| | 26 | ---------- |
| | 27 | TODO. |
| | 28 | |
| | 29 | |
| | 30 | `has_and_belongs_to_many` |
| | 31 | ------------------------- |
| | 32 | TODO. |
| | 33 | ''' |
| | 34 | |