Documentation ¶
Overview ¶
Package matcher is a generated GoMock package.
Index ¶
- func Match(ctx context.Context, ir *claircore.IndexReport, matchers []driver.Matcher, ...) (*claircore.VulnerabilityReport, error)
- type Controller
- type MockMatcher
- func (m *MockMatcher) EXPECT() *MockMatcherMockRecorder
- func (m *MockMatcher) Filter(arg0 *claircore.IndexRecord) bool
- func (m *MockMatcher) Name() string
- func (m *MockMatcher) Query() []driver.MatchConstraint
- func (m *MockMatcher) Vulnerable(arg0 context.Context, arg1 *claircore.IndexRecord, ...) (bool, error)
- type MockMatcherMockRecorder
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Match ¶
func Match(ctx context.Context, ir *claircore.IndexReport, matchers []driver.Matcher, store vulnstore.Vulnerability) (*claircore.VulnerabilityReport, error)
Match receives an IndexReport and creates a VulnerabilityReport containing matched vulnerabilities
Types ¶
type Controller ¶
type Controller struct {
// contains filtered or unexported fields
}
Controller is a control structure used to find vulnerabilities affecting a set of packages.
func NewController ¶
func NewController(m driver.Matcher, store vulnstore.Vulnerability) *Controller
NewController is a constructor for a Controller
func (*Controller) Match ¶
func (mc *Controller) Match(ctx context.Context, records []*claircore.IndexRecord) (map[string][]*claircore.Vulnerability, error)
type MockMatcher ¶
type MockMatcher struct {
// contains filtered or unexported fields
}
MockMatcher is a mock of Matcher interface
func NewMockMatcher ¶
func NewMockMatcher(ctrl *gomock.Controller) *MockMatcher
NewMockMatcher creates a new mock instance
func (*MockMatcher) EXPECT ¶
func (m *MockMatcher) EXPECT() *MockMatcherMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
func (*MockMatcher) Filter ¶
func (m *MockMatcher) Filter(arg0 *claircore.IndexRecord) bool
Filter mocks base method
func (*MockMatcher) Query ¶
func (m *MockMatcher) Query() []driver.MatchConstraint
Query mocks base method
func (*MockMatcher) Vulnerable ¶
func (m *MockMatcher) Vulnerable(arg0 context.Context, arg1 *claircore.IndexRecord, arg2 *claircore.Vulnerability) (bool, error)
Vulnerable mocks base method
type MockMatcherMockRecorder ¶
type MockMatcherMockRecorder struct {
// contains filtered or unexported fields
}
MockMatcherMockRecorder is the mock recorder for MockMatcher
func (*MockMatcherMockRecorder) Filter ¶
func (mr *MockMatcherMockRecorder) Filter(arg0 interface{}) *gomock.Call
Filter indicates an expected call of Filter
func (*MockMatcherMockRecorder) Name ¶
func (mr *MockMatcherMockRecorder) Name() *gomock.Call
Name indicates an expected call of Name
func (*MockMatcherMockRecorder) Query ¶
func (mr *MockMatcherMockRecorder) Query() *gomock.Call
Query indicates an expected call of Query
func (*MockMatcherMockRecorder) Vulnerable ¶
func (mr *MockMatcherMockRecorder) Vulnerable(arg0, arg1, arg2 interface{}) *gomock.Call
Vulnerable indicates an expected call of Vulnerable