sbom

package
v0.0.0-...-bd1132f Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2024 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Overview

Package sbom is a generated GoMock package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GetSbomForDepGraphRequest

type GetSbomForDepGraphRequest struct {
	DepGraphs []json.RawMessage `json:"depGraphs"`
	Subject   Subject           `json:"subject"`
}

type GetSbomForDepGraphResult

type GetSbomForDepGraphResult struct {
	Doc      []byte
	MIMEType string
}

type HTTPSbomClient

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

HTTPSbomClient represents the HTTP client for the SBOM API

func NewHTTPSbomClient

func NewHTTPSbomClient(conf HTTPSbomClientConfig) *HTTPSbomClient

NewHTTPSbomClient creates a new HTTPSbomClient value

func (*HTTPSbomClient) GetSbomForDepGraph

func (c *HTTPSbomClient) GetSbomForDepGraph(
	ctx context.Context,
	orgID, format string,
	req *GetSbomForDepGraphRequest,
) (*GetSbomForDepGraphResult, error)

GetSbomForDepGraph retrieves the SBOM for a depgraph

type HTTPSbomClientConfig

type HTTPSbomClientConfig struct {
	APIHost    string
	Client     *http.Client
	Logger     *zerolog.Logger
	ErrFactory *sbomerrors.SbomErrorFactory
}

HTTPSbomClientConfig represents the configuration for HTTPSbomClient

type MockSbomClient

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

MockSbomClient is a mock of SbomClient interface.

func NewMockSbomClient

func NewMockSbomClient(ctrl *gomock.Controller) *MockSbomClient

NewMockSbomClient creates a new mock instance.

func (*MockSbomClient) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockSbomClient) GetSbomForDepGraph

func (m *MockSbomClient) GetSbomForDepGraph(arg0 context.Context, arg1, arg2 string, arg3 *GetSbomForDepGraphRequest) (*GetSbomForDepGraphResult, error)

GetSbomForDepGraph mocks base method.

type MockSbomClientMockRecorder

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

MockSbomClientMockRecorder is the mock recorder for MockSbomClient.

func (*MockSbomClientMockRecorder) GetSbomForDepGraph

func (mr *MockSbomClientMockRecorder) GetSbomForDepGraph(arg0, arg1, arg2, arg3 interface{}) *gomock.Call

GetSbomForDepGraph indicates an expected call of GetSbomForDepGraph.

type SbomClient

type SbomClient interface {
	GetSbomForDepGraph(context.Context, string, string, *GetSbomForDepGraphRequest) (*GetSbomForDepGraphResult, error)
}

SbomClient provides SBOM generation operations

type Subject

type Subject struct {
	Name    string `json:"name"`
	Version string `json:"version"`
}

type Workflow

type Workflow struct {
	workflows.BaseWorkflow
	// contains filtered or unexported fields
}

Workflow represents the SBOM workflow

func NewWorkflow

func NewWorkflow(sbomClient SbomClient, errFactory *sbomerrors.SbomErrorFactory) *Workflow

NewWorkflow creates a new SBOM workflow value

func (*Workflow) Init

func (w *Workflow) Init(e workflow.Engine) error

Init registers the workflow for the provided engine

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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