// Code generated by mockery v2.46.2. DO NOT EDIT.

package sbom

import (
	context "context"

	model "github.com/goharbor/harbor/src/pkg/scan/sbom/model"
	mock "github.com/stretchr/testify/mock"

	q "github.com/goharbor/harbor/src/lib/q"
)

// Manager is an autogenerated mock type for the Manager type
type Manager struct {
	mock.Mock
}

// Create provides a mock function with given fields: ctx, r
func (_m *Manager) Create(ctx context.Context, r *model.Report) (string, error) {
	ret := _m.Called(ctx, r)

	if len(ret) == 0 {
		panic("no return value specified for Create")
	}

	var r0 string
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, *model.Report) (string, error)); ok {
		return rf(ctx, r)
	}
	if rf, ok := ret.Get(0).(func(context.Context, *model.Report) string); ok {
		r0 = rf(ctx, r)
	} else {
		r0 = ret.Get(0).(string)
	}

	if rf, ok := ret.Get(1).(func(context.Context, *model.Report) error); ok {
		r1 = rf(ctx, r)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// Delete provides a mock function with given fields: ctx, uuid
func (_m *Manager) Delete(ctx context.Context, uuid string) error {
	ret := _m.Called(ctx, uuid)

	if len(ret) == 0 {
		panic("no return value specified for Delete")
	}

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string) error); ok {
		r0 = rf(ctx, uuid)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// DeleteByArtifactID provides a mock function with given fields: ctx, artifactID
func (_m *Manager) DeleteByArtifactID(ctx context.Context, artifactID int64) error {
	ret := _m.Called(ctx, artifactID)

	if len(ret) == 0 {
		panic("no return value specified for DeleteByArtifactID")
	}

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, int64) error); ok {
		r0 = rf(ctx, artifactID)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// DeleteByExtraAttr provides a mock function with given fields: ctx, mimeType, attrName, attrValue
func (_m *Manager) DeleteByExtraAttr(ctx context.Context, mimeType string, attrName string, attrValue string) error {
	ret := _m.Called(ctx, mimeType, attrName, attrValue)

	if len(ret) == 0 {
		panic("no return value specified for DeleteByExtraAttr")
	}

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string, string, string) error); ok {
		r0 = rf(ctx, mimeType, attrName, attrValue)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// GetBy provides a mock function with given fields: ctx, artifactID, registrationUUID, mimeType, mediaType
func (_m *Manager) GetBy(ctx context.Context, artifactID int64, registrationUUID string, mimeType string, mediaType string) ([]*model.Report, error) {
	ret := _m.Called(ctx, artifactID, registrationUUID, mimeType, mediaType)

	if len(ret) == 0 {
		panic("no return value specified for GetBy")
	}

	var r0 []*model.Report
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, int64, string, string, string) ([]*model.Report, error)); ok {
		return rf(ctx, artifactID, registrationUUID, mimeType, mediaType)
	}
	if rf, ok := ret.Get(0).(func(context.Context, int64, string, string, string) []*model.Report); ok {
		r0 = rf(ctx, artifactID, registrationUUID, mimeType, mediaType)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]*model.Report)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, int64, string, string, string) error); ok {
		r1 = rf(ctx, artifactID, registrationUUID, mimeType, mediaType)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// List provides a mock function with given fields: ctx, query
func (_m *Manager) List(ctx context.Context, query *q.Query) ([]*model.Report, error) {
	ret := _m.Called(ctx, query)

	if len(ret) == 0 {
		panic("no return value specified for List")
	}

	var r0 []*model.Report
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, *q.Query) ([]*model.Report, error)); ok {
		return rf(ctx, query)
	}
	if rf, ok := ret.Get(0).(func(context.Context, *q.Query) []*model.Report); ok {
		r0 = rf(ctx, query)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]*model.Report)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, *q.Query) error); ok {
		r1 = rf(ctx, query)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// Update provides a mock function with given fields: ctx, r, cols
func (_m *Manager) Update(ctx context.Context, r *model.Report, cols ...string) error {
	_va := make([]interface{}, len(cols))
	for _i := range cols {
		_va[_i] = cols[_i]
	}
	var _ca []interface{}
	_ca = append(_ca, ctx, r)
	_ca = append(_ca, _va...)
	ret := _m.Called(_ca...)

	if len(ret) == 0 {
		panic("no return value specified for Update")
	}

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, *model.Report, ...string) error); ok {
		r0 = rf(ctx, r, cols...)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// UpdateReportData provides a mock function with given fields: ctx, uuid, report
func (_m *Manager) UpdateReportData(ctx context.Context, uuid string, report string) error {
	ret := _m.Called(ctx, uuid, report)

	if len(ret) == 0 {
		panic("no return value specified for UpdateReportData")
	}

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string, string) error); ok {
		r0 = rf(ctx, uuid, report)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// NewManager creates a new instance of Manager. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewManager(t interface {
	mock.TestingT
	Cleanup(func())
}) *Manager {
	mock := &Manager{}
	mock.Mock.Test(t)

	t.Cleanup(func() { mock.AssertExpectations(t) })

	return mock
}
