Relation - Relation builder function that creates a new RelationDefinition instance with the given name and references. Parameters: - name: a string representing the name of the relation. - references: a variadic parameter representing the relation references associated with this relation. Returns
(name string, references ...*base.RelationReference)
| 135 | // Returns: |
| 136 | // - a pointer to a new RelationDefinition instance with the given name and references. |
| 137 | func Relation(name string, references ...*base.RelationReference) *base.RelationDefinition { |
| 138 | return &base.RelationDefinition{ |
| 139 | Name: name, |
| 140 | RelationReferences: references, |
| 141 | } |
| 142 | } |
| 143 | |
| 144 | // Attribute is a function that generates an attribute definition |
| 145 | // given a name and an attribute type. |