findingsspec

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 14, 2026 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Code generated by strictspec. DO NOT EDIT.

strictspec generator: 0.1.0 schema: strictcode-findings (format_version 1) regenerate: strictspec gen --manifest strictspec.toml

Released under the MIT license (unencumbered). This file is machine-generated; edit the schema and regenerate, never this file.

Index

Constants

View Source
const GeneratedBy = "0.1.0"

GeneratedBy is the strictspec release that produced this file. The runtime pairing guard hard-errors unless it matches the linked runtime exactly.

View Source
const SchemaFormatVersion = 1

SchemaFormatVersion is the document format_version this validator accepts.

Variables

This section is empty.

Functions

This section is empty.

Types

type Finding

type Finding struct {
	Rule     string
	Severity string
	Message  string
	Target   *Target
	Fix      *Fix
}

Finding is the frozen typed binding of the "Finding" record. Fields are immutable by convention (shallow-plus-generated-immutability); use With* for copy-on-write.

func (*Finding) WithFix

func (x *Finding) WithFix(v *Fix) *Finding

WithFix returns a copy of Finding with Fix set to the given value.

func (*Finding) WithMessage

func (x *Finding) WithMessage(v string) *Finding

WithMessage returns a copy of Finding with Message set to the given value.

func (*Finding) WithRule

func (x *Finding) WithRule(v string) *Finding

WithRule returns a copy of Finding with Rule set to the given value.

func (*Finding) WithSeverity

func (x *Finding) WithSeverity(v string) *Finding

WithSeverity returns a copy of Finding with Severity set to the given value.

func (*Finding) WithTarget

func (x *Finding) WithTarget(v *Target) *Finding

WithTarget returns a copy of Finding with Target set to the given value.

type Findings

type Findings struct {
	StrictcodeVersion string
	WorkspaceRoot     string
	Findings          []*Finding
}

Findings is the frozen typed binding of the "Findings" record. Fields are immutable by convention (shallow-plus-generated-immutability); use With* for copy-on-write.

func ValidateBytes

func ValidateBytes(input []byte, syntax string) (*Findings, []strictspec.Diagnostic)

ValidateBytes is the raw-bytes entry point: lossless parse of input in the given syntax ("json" | "toml" | "jsonl"), then validate. It returns the typed root value (nil when any diagnostic fired) and the ordered diagnostics.

func ValidateBytesWithEvidence

func ValidateBytesWithEvidence(input []byte, syntax string, evidence map[string][]map[string]any) (*Findings, []strictspec.Diagnostic)

ValidateBytesWithEvidence is ValidateBytes plus cross-document resolver evidence for the phase-2 constraint vocabulary.

func ValidateValue

func ValidateValue(v strictspec.Value) (*Findings, []strictspec.Diagnostic)

ValidateValue is the tagged-value entry point: validate an already-parsed tagged document value (from strictspec.LoadValue or a typed constructor).

func (*Findings) WithFindings

func (x *Findings) WithFindings(v []*Finding) *Findings

WithFindings returns a copy of Findings with Findings set to the given value.

func (*Findings) WithStrictcodeVersion

func (x *Findings) WithStrictcodeVersion(v string) *Findings

WithStrictcodeVersion returns a copy of Findings with StrictcodeVersion set to the given value.

func (*Findings) WithWorkspaceRoot

func (x *Findings) WithWorkspaceRoot(v string) *Findings

WithWorkspaceRoot returns a copy of Findings with WorkspaceRoot set to the given value.

type Fix

type Fix struct {
	Tier        int64
	Description string
}

Fix is the frozen typed binding of the "Fix" record. Fields are immutable by convention (shallow-plus-generated-immutability); use With* for copy-on-write.

func (*Fix) WithDescription

func (x *Fix) WithDescription(v string) *Fix

WithDescription returns a copy of Fix with Description set to the given value.

func (*Fix) WithTier

func (x *Fix) WithTier(v int64) *Fix

WithTier returns a copy of Fix with Tier set to the given value.

type Target

type Target struct {
	Id   string
	Kind string
	File string
	Line int64
}

Target is the frozen typed binding of the "Target" record. Fields are immutable by convention (shallow-plus-generated-immutability); use With* for copy-on-write.

func (*Target) WithFile

func (x *Target) WithFile(v string) *Target

WithFile returns a copy of Target with File set to the given value.

func (*Target) WithId

func (x *Target) WithId(v string) *Target

WithId returns a copy of Target with Id set to the given value.

func (*Target) WithKind

func (x *Target) WithKind(v string) *Target

WithKind returns a copy of Target with Kind set to the given value.

func (*Target) WithLine

func (x *Target) WithLine(v int64) *Target

WithLine returns a copy of Target with Line set to the given value.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL