Skip to main content

Module model

Module model 

Source
Expand description

Core data model: graph, nodes, edges.

Structs§

Attr
One attribute row inside an entity block: type name [PK|FK|UK] ["comment"].
Class
A class box: name header + fields compartment + methods compartment.
ClassDiagram
UML class diagram (classDiagram header).
ClassRel
A relationship between two classes. Normalised so the end glyph (triangle / diamond / arrow) always sits at the to end.
Edge
Entity
A database entity, rendered as a table.
ErDiagram
Entity-Relationship diagram (erDiagram header).
Graph
Parsed graph, ready for layout.
Journey
A user-journey diagram (journey header): an ordered list of sections, each holding scored tasks. actors is the de-duplicated set of every participant, in first-appearance order — its index is the stable color key for the legend and per-task dots.
JourneySection
A named group of consecutive tasks (section X). Tasks before the first section land in one leading section with an empty name.
JourneyTask
One step: Task name: score: Actor1, Actor2. score is clamped to 1..=5 (satisfaction); actors are indices into Journey::actors.
Member
One field or method row.
MindNode
One mindmap node. text may contain \n (from <br/>) for a multi-line label. branch is the index of the depth-1 ancestor this node descends from (its colored branch); None for the root.
Mindmap
A mindmap (mindmap header): a single-rooted tree of text nodes whose hierarchy comes from source indentation. nodes[0] is always the root; every other node has a parent. Parse order is preserved, so sibling order (and thus layout order) is stable across renders.
Node
NodeStyle
Custom per-node styling from Mermaid style / classDef lines. None fields fall back to the shape’s theme color (see crate::style::shape_style).
Participant
One lifeline column: participant A [as Label] / actor A.
PieChart
Pie chart (pie header). Slices keep source order; a duplicate label keeps one slice whose value is the LAST one written.
PieSlice
One pie data row: "Quoted Label" : value (non-negative).
Relation
Relationship between two entities. card_from describes the from side, card_to the to side (crow’s foot notation).
SequenceDiagram
Sequence diagram (sequenceDiagram header). Items keep source order — the layout is one row per item, top-down.
SubEdge
An edge where at least one endpoint is a subgraph (CF --> VPC). Kept apart from Edge so the flat node→node path stays untouched; consumed only by the clustered scene.
Subgraph
A subgraph ... end block: a titled cluster of nodes, possibly nested. Membership is by node index; nested members belong to the child, not the parent (walk parent links for the chain).

Enums§

Card
Relationship cardinality on one side.
Direction
Flow direction of the diagram.
Document
One parsed Mermaid document of any supported diagram type. Produced by crate::parser::parse_document.
EdgeKind
Edge line style.
End
One endpoint of an edge that touches a subgraph — either a regular node or a whole subgraph (its cluster box).
FrameKind
Kind of a loop / opt / alt / par frame.
Key
Attribute key marker.
MindShape
Node outline in a mindmap, from the wrapper around its text.
NoteSide
Where a note attaches.
RelKind
UML relationship type (determines line style + end glyph).
SeqHead
Arrowhead at the target end of a message.
SeqItem
One statement of a sequence diagram, in source order.
Shape
Node shape.
Visibility
UML member visibility, shown as a leading glyph.