Documentation
¶
Overview ¶
Package generate proposes catalog entries for the routes of the inventory: parameter values from the configuration, the pristine database or earlier responses, and one entry per template (ok, not-found, json…). Entries written by hand or imported are kept as they are; generated entries are replaced on every run, in the same order every time.
Index ¶
Constants ¶
const SequencePrefix = "gen-after-"
SequencePrefix marks sequences that generate made.
Variables ¶
This section is empty.
Functions ¶
func FormFields ¶
FormFields writes a JSON object as form fields, the way PHP and most frameworks read them back: nested keys in brackets (address[city]), list items by index (tags[0]), true as 1 and false as 0, null as empty.
func IsGenerated ¶
IsGenerated reports whether an entry came from generate.
Types ¶
type Options ¶
type Options struct {
Project *config.Project
Inventory *routes.Inventory
Exclusions *routes.Exclusions
Existing *catalog.Catalog
Query Query
All bool // also routes that entries written by hand already reach
}
Options of one run.