ErRelationship Class

A relationship between two elements of an entity relationship diagram.

public sealed class ErRelationship

Constructors

NameDescription
ErRelationship(ErElement, ErElement)Initializes a new instance of the ErRelationship class.

ErRelationship(ErElement, ErElement)

ErRelationship.cs

Initializes a new instance of the ErRelationship class.

public ErRelationship(ErElement from, ErElement to)

Parameters

from ErElement
The first element, written on the left in Mermaid.
to ErElement
The second element, written on the right in Mermaid.

Properties

NameDescription
FromGets the first element.
FromCardinalityGets or sets how many instances of ErRelationship.From an instance of ErRelationship.To relates to, drawn at ErRelationship.From.
IsIdentifyingGets or sets a value that indicates whether the relationship is identifying, drawn with a solid line: the child entity cannot exist without the other one. A non-identifying relationship is dashed (Mermaid ..). The default is true.
LabelGets or sets the text of the relationship, from the point of view of ErRelationship.From, or null for none.
ToGets the second element.
ToCardinalityGets or sets how many instances of ErRelationship.To an instance of ErRelationship.From relates to, drawn at ErRelationship.To.

Gets the first element.

public ErElement From { get; }

Property value

ErElement

FromCardinality

ErRelationship.cs

Gets or sets how many instances of ErRelationship.From an instance of ErRelationship.To relates to, drawn at ErRelationship.From.

public ErCardinality FromCardinality { get; set; }

Property value

ErCardinality

IsIdentifying

ErRelationship.cs

Gets or sets a value that indicates whether the relationship is identifying, drawn with a solid line: the child entity cannot exist without the other one. A non-identifying relationship is dashed (Mermaid ..). The default is true.

public bool IsIdentifying { get; set; }

Property value

bool

Gets or sets the text of the relationship, from the point of view of ErRelationship.From, or null for none.

public DiagramText? Label { get; set; }

Property value

DiagramText?

Gets the second element.

public ErElement To { get; }

Property value

ErElement

ToCardinality

ErRelationship.cs

Gets or sets how many instances of ErRelationship.To an instance of ErRelationship.From relates to, drawn at ErRelationship.To.

public ErCardinality ToCardinality { get; set; }

Property value

ErCardinality