Move RelationshipType naming convention to Markdown guide instead#1135
Move RelationshipType naming convention to Markdown guide instead#1135bact wants to merge 3 commits intospdx:developfrom
Conversation
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
| A relationship can be either directional or non-directional (directionless). | ||
| For a directional relationship, | ||
| the direction of a relationship is always from the `from` Element to the | ||
| `to` Element, as defined by the `relationshipType` property. |
There was a problem hiding this comment.
Sorry, I do no understand this.
What are these two types of relationships (directional and directionless)?
And what does it mean that the relationshipType property "defines" from and to?
There was a problem hiding this comment.
What are these two types of relationships (directional and directionless)?
This is a directional relationship.
graph LR;
A[from] -->|directional relationship| B[to]
This is a directionless relationship.
graph LR;
A[from] ---|non-directional relationship| B[to]
Since v3.0.1 https://spdx.github.io/spdx-spec/v3.0.1/model/Core/Vocabularies/RelationshipType/, we have one directionless relationship type, which is "other":
other: Every
toElement is related to thefromElement where the relationship type is not described by any of the SPDX relationship types (this relationship is directionless).
The rest are directional.
--
And what does it mean that the relationshipType property "defines" from and to?
The text didn't say that.
It said the relationshipType defines the direction of a relationship.
This aligns with the last paragraph of RelationshipType description:
Relationship names should be descriptive enough to easily deduce the correct direction from their name.
Relationshipdescription.RelationshipTypedescription and put them to the "Naming convention" section in the Markdown guide (docs/format.md) instead.RELATIONSHIPis in capital letters, looks like it is from SPDX 2 - should remove it.