gotable

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package gotable transforms evaluation results to a go table object, from there it can be rendererd to html, markup, etc.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type TableBuilder

type TableBuilder struct {
	Decorator TableDecorator
}

func (*TableBuilder) ResultGroupTable added in v1.1.0

func (tb *TableBuilder) ResultGroupTable(grp *papi.ResultGroup) (table.Writer, error)

ResultGroupTable renders a single group evaluation result

func (*TableBuilder) ResultSetTable

func (tb *TableBuilder) ResultSetTable(set *papi.ResultSet) (table.Writer, error)

RenderResult renders a single evaluation result

func (*TableBuilder) ResultsTable

func (tb *TableBuilder) ResultsTable(result *papi.Result) (table.Writer, error)

RenderResult renders a single evaluation result

type TableDecorator

type TableDecorator interface {
	AmpelBanner(string) string
	SubjectToString(attestation.Subject, []*papi.ChainedSubject) string
	AssessmentToString(*papi.Assessment) string
	ErrorToString(*papi.Error) string
	StatusToDot(string) string
	ControlsToString(result *papi.Result, checkID, def string) string
	TenetsToString(result *papi.Result) string
	Bold(string) string
}

TableDecorator is an object that renders the format specific decoration of the tabular reports.

Jump to

Keyboard shortcuts

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