Skip to content

@graphty/graphty-element / index / ExportLossCode

Type Alias: ExportLossCode ​

ExportLossCode = CodesOf<typeof LOSS> | CodesOf<typeof CSV_LOSS> | CodesOf<typeof CX_LOSS> | CodesOf<typeof CX2_LOSS> | CodesOf<typeof CYS_LOSS> | CodesOf<typeof DOT_LOSS> | CodesOf<typeof GEXF_LOSS> | CodesOf<typeof GML_LOSS> | CodesOf<typeof GRAPHML_LOSS> | CodesOf<typeof JSON_LOSS> | CodesOf<typeof NEO4J_LOSS> | CodesOf<typeof PAJEK_LOSS> | CodesOf<typeof XGMML_LOSS> | "W_GRAPHTY_COLUMN_DROPPED" | "W_GRAPHTY_NOTES" | "W_GRAPHTY_TRUNCATED" | "W_GRAPHTY_CSV_NEUTRALIZED" | "W_WEIGHT_NOT_NUMERIC" | "W_RESULT_FIELD_DROPPED" | ExportStyleLossCode

Defined in: graphty-element/src/data/export.ts:118

What a built-in writer could not carry, as the code of an ExportLoss: the codes of graph-io's loss tables for the formats graphty-element writes (LOSS, shared by every format, and CSV_LOSS, CX_LOSS, CX2_LOSS, CYS_LOSS, DOT_LOSS, GEXF_LOSS, GML_LOSS, GRAPHML_LOSS, JSON_LOSS, NEO4J_LOSS, PAJEK_LOSS, XGMML_LOSS, each documenting its codes), and graphty-element's own:

  • W_GRAPHTY_COLUMN_DROPPED: a loaded column under the reserved graphty. root is left out.
  • W_GRAPHTY_NOTES: the session holds notes, which no format holds as notes; count notes.
  • W_GRAPHTY_TRUNCATED: graphty.notes.text cells cut to 64 KB; count cells.
  • W_GRAPHTY_CSV_NEUTRALIZED: CSV cells a spreadsheet would run as a formula, prefixed with an apostrophe; count cells.
  • W_WEIGHT_NOT_NUMERIC: edge weights that are not numbers, not written; count edges.
  • W_RESULT_FIELD_DROPPED: an algorithm result field no column could hold.
  • The style codes of ExportStyleLossCode: each names its target (node, edge or graph) and property (a neutral property such as fill, or graphty:<channel> for a channel only graphty draws, which then also names that channel, such as node.labelColor) where it is about one; W_STYLE_NOT_WRITTEN counts the elements that carry a value, W_STYLE_RULES_NOT_KEPT the rules, W_STYLES_NOT_EXPORTED the layers an export without styles: true left out, and W_STYLE_LAYER_FLATTENED adds layer (its name) and reason (SCALE: a palette or a scale the format cannot express; RESULT_PATH: it reads a value the file does not hold, such as an algorithm result).

A code starting E_ means the writer refuses this graph under these options: text() and bytes reject. W_ means the file is written but that part does not read back the same.