db

package
v0.0.0-...-b0fec18 Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2024 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

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 Queries

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

func New

func New(db DBTX) *Queries

func (*Queries) RepoArtifactByType

func (q *Queries) RepoArtifactByType(ctx context.Context, arg RepoArtifactByTypeParams) ([]RepositoryArtifact, error)

func (*Queries) RepoArtifacts

func (q *Queries) RepoArtifacts(ctx context.Context, repositoryID int64) ([]RepositoryArtifact, error)

func (*Queries) RepoCreate

func (q *Queries) RepoCreate(ctx context.Context, arg RepoCreateParams) (Repository, error)

func (*Queries) RepoUpdateArtifact

func (q *Queries) RepoUpdateArtifact(ctx context.Context, arg RepoUpdateArtifactParams) error

func (*Queries) RepoUpsert

func (q *Queries) RepoUpsert(ctx context.Context, arg RepoUpsertParams) (Repository, error)

func (*Queries) RepoUpsertArtifact

func (q *Queries) RepoUpsertArtifact(ctx context.Context, arg RepoUpsertArtifactParams) (RepositoryArtifact, error)

func (*Queries) ReposByNameLike

func (q *Queries) ReposByNameLike(ctx context.Context, name string) ([]Repository, error)

func (*Queries) ReposByUsernameLike

func (q *Queries) ReposByUsernameLike(ctx context.Context, username string) ([]Repository, error)

func (*Queries) ReposGetAll

func (q *Queries) ReposGetAll(ctx context.Context) ([]Repository, error)

func (*Queries) WithTx

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

type RepoArtifactByTypeParams

type RepoArtifactByTypeParams struct {
	RepositoryID int64
	DataType     string
}

type RepoCreateParams

type RepoCreateParams struct {
	RemoteID    string
	Name        string
	Username    string
	Description string
	HtmlUrl     string
	CloneUrl    string
	CloneSshUrl string
	IsFork      bool
	ForkUrl     string
}

type RepoUpdateArtifactParams

type RepoUpdateArtifactParams struct {
	Data         []byte
	RepositoryID int64
	DataType     string
}

type RepoUpsertArtifactParams

type RepoUpsertArtifactParams struct {
	RepositoryID int64
	DataType     string
	Data         []byte
}

type RepoUpsertParams

type RepoUpsertParams struct {
	RemoteID    string
	Name        string
	Username    string
	Description string
	HtmlUrl     string
	CloneUrl    string
	CloneSshUrl string
	IsFork      bool
	ForkUrl     string
}

type Repository

type Repository struct {
	ID          int64
	RemoteID    string
	Name        string
	Username    string
	Description string
	HtmlUrl     string
	CloneUrl    string
	CloneSshUrl string
	IsFork      bool
	ForkUrl     string
}

type RepositoryArtifact

type RepositoryArtifact struct {
	ID           int64
	DataType     string
	Data         []byte
	RepositoryID int64
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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