db

package
v0.67.1 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CreateTablesQuery string

Functions

This section is empty.

Types

type DBTX

type DBTX interface {
	ExecContext(context.Context, string, ...interface{}) (sql.Result, error)
	PrepareContext(context.Context, string) (*sql.Stmt, error)
	QueryContext(context.Context, string, ...interface{}) (*sql.Rows, error)
	QueryRowContext(context.Context, string, ...interface{}) *sql.Row
}

type Dependabot

type Dependabot struct {
	Platform        string
	Organisation    string
	Repo            string
	PackageName     string
	Version         string
	CurrentVersion  sql.NullString
	PackageManager  string
	PackageFilePath string
}

type InsertPackageParams

type InsertPackageParams struct {
	Platform        string
	Organisation    string
	Repo            string
	PackageName     string
	Version         string
	CurrentVersion  sql.NullString
	PackageManager  string
	PackageFilePath string
}

type Queries

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

func New

func New(db DBTX) *Queries

func (*Queries) AnonymiseOrgAndRepo added in v0.13.0

func (q *Queries) AnonymiseOrgAndRepo(ctx context.Context) error

func (*Queries) AnonymisePackageFilePathByOrg added in v0.13.0

func (q *Queries) AnonymisePackageFilePathByOrg(ctx context.Context, packageFilePath string) error

func (*Queries) AnonymisePackageNameByOrg added in v0.13.0

func (q *Queries) AnonymisePackageNameByOrg(ctx context.Context, packageName string) error

func (*Queries) InsertPackage

func (q *Queries) InsertPackage(ctx context.Context, arg InsertPackageParams) error

func (*Queries) RetrieveAll added in v0.4.0

func (q *Queries) RetrieveAll(ctx context.Context) ([]Dependabot, error)

func (*Queries) WithTx

func (q *Queries) WithTx(tx *sql.Tx) *Queries

Jump to

Keyboard shortcuts

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