@graphty/graphty-element / extend / DeclaredDirection
Interface: DeclaredDirection ​
Defined in: graphty-element/src/data/DataSource.ts:268
What a file said about its own direction, as its parser read it.
A graph is directed or it is not, and the snapshot carries exactly one flag for the whole graph, so this is one boolean and not a per-edge answer. null from a data source means the FILE said nothing -- an edge list with no header that names direction, a JSON document with no directed key -- and a source that says nothing leaves the element's own data.directed configuration standing, which is what "auto" means.
Properties ​
conflictingEdges ​
readonlyconflictingEdges:number
Defined in: graphty-element/src/data/DataSource.ts:289
How many edges carried a direction of their own that disagrees with directed.
Formats that can state direction twice -- GEXF's per-edge type, GraphML's per-edge directed, a Pajek file with both an *Arcs and an *Edges section, a Gephi CSV whose Type column varies by row -- can describe a MIXED graph, which neither graph-format nor the element can represent: the snapshot has one direction flag. The importers resolve the disagreement rather than dropping half of it, and count what they overrode here so the element can say out loud that it did.
Zero for a format that cannot state direction per edge, and for one that can but did not.
directed ​
readonlydirected:boolean
Defined in: graphty-element/src/data/DataSource.ts:270
True when the file declares a directed graph.
statedBy ​
readonlystatedBy:string
Defined in: graphty-element/src/data/DataSource.ts:276
The part of the file that said so, spelled the way the file spells it (defaultedgetype="undirected", digraph, *Arcs), so that a log line naming a disagreement can point at the text a reader can go and look at.