ketchup

package
v1.17.0 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2021 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

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

App of package

func New

func New(db model.Database) App

New creates new App from Config

func (App) Create

func (a App) Create(ctx context.Context, o model.Ketchup) (uint64, error)

Create a ketchup

func (App) Delete

func (a App) Delete(ctx context.Context, o model.Ketchup) error

Delete a ketchup

func (App) DoAtomic added in v1.2.0

func (a App) DoAtomic(ctx context.Context, action func(context.Context) error) error

DoAtomic does an atomic operation

func (App) GetByRepository added in v1.14.0

func (a App) GetByRepository(ctx context.Context, id uint64, pattern string, forUpdate bool) (model.Ketchup, error)

GetByRepository retrieves ketchup for a repository and patern

func (App) List

func (a App) List(ctx context.Context, pageSize uint, last string) ([]model.Ketchup, uint64, error)

List ketchups

func (App) ListByRepositoriesID

func (a App) ListByRepositoriesID(ctx context.Context, ids []uint64, frequency model.KetchupFrequency) ([]model.Ketchup, error)

ListByRepositoriesID lists ketchup by repositories id

func (App) ListOutdatedByFrequency added in v1.12.0

func (a App) ListOutdatedByFrequency(ctx context.Context, frequency model.KetchupFrequency, userIds ...uint64) ([]model.Ketchup, error)

ListOutdatedByFrequency lists outdated ketchup by frequency id

func (App) Update

func (a App) Update(ctx context.Context, o model.Ketchup, oldPattern string) error

Update a ketchup

func (App) UpdateAll added in v1.15.0

func (a App) UpdateAll(ctx context.Context) error

UpdateAll ketchups

func (App) UpdateVersion added in v1.17.0

func (a App) UpdateVersion(ctx context.Context, userID, repositoryID uint64, pattern, version string) error

UpdateVersion of a ketchup

Jump to

Keyboard shortcuts

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