output_workflow

package
v0.54.0 Latest Latest
Warning

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

Go to latest
Published: Nov 24, 2026 License: Apache-2.0 Imports: 19 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	OUTPUT_CONFIG_KEY_JSON               = "json"
	OUTPUT_CONFIG_KEY_JSON_FILE          = "json-file-output"
	OUTPUT_CONFIG_KEY_SARIF              = "sarif"
	OUTPUT_CONFIG_KEY_SARIF_FILE         = "sarif-file-output"
	OUTPUT_CONFIG_KEY_HTML               = "html"
	OUTPUT_CONFIG_KEY_HTML_FILE          = "html-file-output"
	OUTPUT_CONFIG_TEMPLATE_FILE          = "internal_template_file"
	OUTPUT_CONFIG_KEY_FILE_WRITERS       = "internal_output_file_writers"
	OUTPUT_CONFIG_KEY_DEFAULT_WRITER_LUT = "internal_default_writer_mimetype_lut"
	OUTPUT_CONFIG_KEY_NO_DEFAULT_WRITER  = "internal_no_default_writer"
	DEFAULT_WRITER                       = "default"
	DEFAULT_MIME_TYPE                    = presenters.DefaultMimeType
	SARIF_MIME_TYPE                      = presenters.ApplicationSarifMimeType
	JSON_MIME_TYPE                       = presenters.ApplicationJSONMimeType
	HTML_MIME_TYPE                       = presenters.ApplicationHTMLMimeType
)

Variables

View Source
var ApplicationHTMLTemplatesUfm = presenters.ApplicationHTMLTemplatesUfm
View Source
var ApplicationSarifTemplates = presenters.ApplicationSarifTemplates
View Source
var ApplicationSarifTemplatesUfm = presenters.ApplicationSarifTemplatesUfm
View Source
var DefaultTemplateFiles = presenters.DefaultTemplateFiles

DefaultTemplateFiles is an instance of TemplatePathsStruct with the template paths.

Functions

func DefaultOutputIsStructured

func DefaultOutputIsStructured(config configuration.Configuration) bool

func HandleContentTypeFindingsModel

func HandleContentTypeFindingsModel(input []workflow.Data, invocation workflow.InvocationContext, writers WriterMap) ([]workflow.Data, error)

func HandleContentTypeOther

func HandleContentTypeOther(input []workflow.Data, invocation workflow.InvocationContext, writers WriterMap) ([]workflow.Data, error)

func HandleContentTypeUnifiedModel

func HandleContentTypeUnifiedModel(input []workflow.Data, invocation workflow.InvocationContext, writers WriterMap) ([]workflow.Data, error)

HandleContentTypeUnifiedModel handles the unified model content type.

Types

type FileWriter

type FileWriter struct {
	NameConfigKey     string   // defines the configuration key to look up the filename under
	MimeType          string   // defines the final mime type of the rendering
	TemplateFiles     []string // defines the set of template files to use for rendering
	WriteEmptyContent bool     // specifies if anything should be written at all if the input data is empty
}

FileWriter is a public structure used to configure file based rendering

type MimeType2Template

type MimeType2Template struct {
	// contains filtered or unexported fields
}

type WriterEntry

type WriterEntry struct {
	// contains filtered or unexported fields
}

WriterEntry is an internal structure to handle all template based writers

func (*WriterEntry) GetWriter

func (we *WriterEntry) GetWriter() io.WriteCloser

type WriterMap

type WriterMap interface {
	PopWritersByMimetype(mimeType string) []*WriterEntry
	Length() int
	AvailableMimetypes() []string
	String() string
}

func GetWritersFromConfiguration

func GetWritersFromConfiguration(config configuration.Configuration, outputDestination iUtils.OutputDestination) WriterMap

Jump to

Keyboard shortcuts

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