17#ifndef A11_FLOW_NAVIGATE_H_
18#define A11_FLOW_NAVIGATE_H_
83std::vector<DocumentSymbol>
Symbols(std::string_view source);
117 std::string_view source,
size_t offset,
132 bool required,
bool unary,
Everything the tools know about the world, in one place.
Definition catalogue.h:119
static const Catalogue & Builtin()
The embedded snapshot: what a standalone tool knows with nothing configured.
Definition catalogue.cc:424
WordRole
Which table a word is documented in.
Definition vocabulary.h:162
Definition boundary.cc:32
Description Describe(std::string_view source, size_t offset, const catalogue::Catalogue &known)
What is at offset, and where it came from.
Definition navigate.cc:632
std::string BuiltinMarkdown(std::string_view name)
A built-in function, the same way.
Definition navigate.cc:422
std::string_view SymbolClassName(SymbolClass kind)
Definition navigate.cc:474
std::string FlowMarkdown(const FlowPlan &flow)
A flow of the document, written out the same way: what it does, then its ports and which direction ea...
Definition navigate.cc:452
@ kPort
A port of this flow, or of a call.
@ kCall
A bound run/call step.
@ kField
A field of something: a status's code, a node's id.
@ kHeader
A header, under its alias.
@ kNode
A node of the flow's own.
@ kFlow
A flow of this file, offered as a call target.
@ kVariable
A loop variable, the index a loop binds, or what a repeat carries.
@ kBarrier
A bound wait/drain.
std::string PortMarkdown(std::string_view name, std::string_view type, bool required, bool unary, std::string_view description)
One port, written out as the Markdown a reader wants beside its name.
Definition navigate.cc:439
std::string WordMarkdown(std::string_view name, vocabulary::WordRole role)
One word or mark of the language, written out as reference: what it does, what it takes,...
Definition navigate.cc:406
std::string ActionMarkdown(const catalogue::ActionInfo &action)
An action, written out as the Markdown a reader wants to see: what it does, then every port it has.
Definition navigate.cc:426
constexpr std::string_view kHoverFormat
The format field of the hover envelope.
Definition navigate.h:169
std::string StageMarkdown(std::string_view name)
A pipeline stage, written out as reference.
Definition navigate.cc:418
constexpr std::string_view kSymbolsFormat
The format field of the symbols envelope.
Definition navigate.h:167
SymbolClass
Moving around a document: what is under the caret, what the file declares, and where a name was bound...
Definition navigate.h:44
@ kExternal
Something the language knows about but the document did not declare: an action, a registered type,...
std::vector< DocumentSymbol > Symbols(std::string_view source)
Every symbol a document declares, nested as it is written.
Definition navigate.cc:559
constexpr std::string_view kDefinitionFormat
The format field of the definition envelope.
Definition navigate.h:171
std::string ShapeMarkdown(const DtoPlan &shape)
A struct, written out the same way: how many fields, then each of them.
Definition navigate.cc:466
std::string shape
The shape this stream's values are, where the flow said so: a port typed with a struct,...
Definition resolve.cc:715
What is at one offset, described.
Definition navigate.h:86
std::optional< catalogue::Origin > origin
Where it was declared, when it was declared in another file and something read that file: an action o...
Definition navigate.h:112
Range definition
Definition navigate.h:104
Range range
What the word covers, so an editor can underline exactly it.
Definition navigate.h:101
std::string text
The word or construct itself, as written.
Definition navigate.h:91
std::string detail
Everything else worth reading: an action's description and its ports, a shape's fields,...
Definition navigate.h:97
std::string summary
One line: what it is. an action, ‘a port of 'search’`.
Definition navigate.h:94
std::string markdown
The same as Markdown, which is what an editor's hover wants.
Definition navigate.h:99
SymbolClass kind
Definition navigate.h:92
bool found
Whether anything is there at all.
Definition navigate.h:89
bool has_definition
Where it was declared, when it was declared in this document.
Definition navigate.h:103
One thing a document declares, and the things declared inside it.
Definition navigate.h:63
std::string name
Definition navigate.h:64
bool port_required
Definition navigate.h:72
std::vector< DocumentSymbol > children
Definition navigate.h:77
SymbolClass kind
Definition navigate.h:65
Range selection
Just the name, for "put the caret here".
Definition navigate.h:76
std::string port_type
Definition navigate.h:70
Range range
The whole construct, for "select this symbol".
Definition navigate.h:74
bool port_stream
Definition navigate.h:71
std::string detail
What an editor shows beside the name: a port's type, a call's action.
Definition navigate.h:67
std::string port_direction
Port metadata, populated only when kind is kPort.
Definition navigate.h:69
One compiled struct: a shape a port may be typed with.
Definition plan.h:80
One compiled flow: what a caller sees, and what the runtime will do.
Definition plan.h:149
Half-open span of source, [start, end).
Definition diagnostic.h:79
One action a flow may run or call.
Definition catalogue.h:88
long long offset
Definition main.cc:69