Documentation
¶
Overview ¶
Package docs holds Sonde's single compatibility doc-data source (table.yaml) and its typed accessors. docs/compat.md and the LSP's hover text are both rendered from this table so they can never drift from each other.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RenderCompat ¶
RenderCompat renders docs/compat.md from t using compat.md.tmpl. The result is deterministic for a given Table.
Types ¶
type Difference ¶
type Difference struct {
Area string `yaml:"area"`
Input string `yaml:"input"`
Hurl string `yaml:"hurl"`
Sonde string `yaml:"sonde"`
}
Difference is one row of documented behavior that differs from the reference implementation for inputs outside the conformance test tree.
type Entry ¶
type Entry struct {
Name string `yaml:"name"`
Status Status `yaml:"status"`
Phase int `yaml:"phase,omitempty"`
Doc string `yaml:"doc"`
Reason string `yaml:"reason,omitempty"`
Usage int `yaml:"usage,omitempty"`
Short string `yaml:"short,omitempty"`
Arg string `yaml:"arg,omitempty"`
// Deprecated names the replacement of a deprecated entry.
Deprecated string `yaml:"deprecated,omitempty"`
// Since is the reference version that added the entry, when it is
// newer than the one the conformance gate runs (8.0.1); its usage is
// counted in that version's test tree.
Since string `yaml:"since,omitempty"`
}
Entry is one query, filter, predicate, template function, request [Options] key, CLI flag, environment variable or config-file key.
type SondeTable ¶ added in v1.2.0
type SondeTable struct {
Sections []Entry `yaml:"sections"`
GrpcKeys []Entry `yaml:"grpc_keys"`
Steps []Entry `yaml:"steps"`
Options []Entry `yaml:"options"`
Queries []Entry `yaml:"queries"`
}
SondeTable lists the Sonde extensions of the file format, valid only in .sonde files.
type Table ¶
type Table struct {
Queries []Entry `yaml:"queries"`
Filters []Entry `yaml:"filters"`
Predicates []Entry `yaml:"predicates"`
Functions []Entry `yaml:"functions"`
Options []Entry `yaml:"options"`
Flags []Entry `yaml:"flags"`
Env []Entry `yaml:"env"`
Config []Entry `yaml:"config"`
Sonde SondeTable `yaml:"sonde"`
Differences []Difference `yaml:"differences"`
}
Table is the decoded, validated content of table.yaml.
func Load ¶
Load returns the parsed, validated table.yaml. The result is cached; the returned *Table must be treated as read-only.
func (*Table) Lookup ¶
Lookup returns the entry named name within kind ("queries", "filters", "predicates", "functions", "options", "flags", "env", "config", or a Sonde extension kind: "sonde-sections", "sonde-grpc-keys", "sonde-steps", "sonde-options", "sonde-queries"), used by the LSP for hover text.