Skip to main content

snapshot

Function snapshot 

Source
pub fn snapshot(
    app: &App,
    models: &[&'static ModelMeta],
    settings: &CliSettings,
    limits: Limits,
) -> Envelope<Snapshot>
Expand description

Build the snapshot of app, its registered models and settings within limits.

Args: app: A freshly built app (no connection is opened). models: The registered model metadata. settings: The CLI settings; only alias names and URL schemes are read. limits: Size bounds.

Returns: The snapshot envelope. A truncated section adds a snapshot.W001 warning; an OpenAPI document that cannot be generated adds a snapshot.E001 error and leaves routes and spec empty and marked incomplete.