report

package
v0.4.14 Latest Latest
Warning

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

Go to latest
Published: Feb 4, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LISTMARK = "*"
	COLON    = ":"
	SPACE    = " "
	TAB      = "	"
	NEWLINE  = "\n"
)

Variables

View Source
var AlertLabels = map[int]string{
	types.InfoLevel:   "INFO",
	types.WarnLevel:   "WARN",
	types.FatalLevel:  "FATAL",
	types.PassLevel:   "PASS",
	types.SkipLevel:   "SKIP",
	types.IgnoreLevel: "IGNORE",
}

Functions

This section is empty.

Types

type JsonDetail

type JsonDetail struct {
	Code   string   `json:"code"`
	Title  string   `json:"title"`
	Level  string   `json:"level"`
	Alerts []string `json:"alerts"`
}

type JsonOutputFormat

type JsonOutputFormat struct {
	ImageName string        `json:"image,omitempty"`
	Summary   JsonSummary   `json:"summary"`
	Details   []*JsonDetail `json:"details"`
}

type JsonSummary

type JsonSummary struct {
	Fatal int `json:"fatal"`
	Warn  int `json:"warn"`
	Info  int `json:"info"`
	Skip  int `json:"skip"`
	Pass  int `json:"pass"`
}

type JsonWriter

type JsonWriter struct {
	ImageName string
	Output    io.Writer
}

func (JsonWriter) Write

func (jw JsonWriter) Write(assessMap types.AssessmentMap) (abend bool, err error)

type ListWriter

type ListWriter struct {
	Output  io.Writer
	NoColor bool
}

func (ListWriter) Write

func (lw ListWriter) Write(assessMap types.AssessmentMap) (abend bool, err error)

type SarifWriter added in v0.3.14

type SarifWriter struct {
	Output io.Writer
}

func (SarifWriter) Write added in v0.3.14

func (sw SarifWriter) Write(assessMap types.AssessmentMap) (abend bool, err error)

type Writer

type Writer interface {
	Write(assessments types.AssessmentMap) (bool, error)
}

Jump to

Keyboard shortcuts

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