dbclient

package
v0.0.0-...-d002fe6 Latest Latest
Warning

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

Go to latest
Published: May 10, 2020 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GormClient

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

func NewGormClient

func NewGormClient(cfg *cmd.Config) *GormClient

func (*GormClient) Check

func (gc *GormClient) Check() bool

func (*GormClient) Close

func (gc *GormClient) Close()

func (*GormClient) QueryAccountImage

func (gc *GormClient) QueryAccountImage(ctx context.Context, accountId string) (model.AccountImage, error)

func (*GormClient) SeedAccountImages

func (gc *GormClient) SeedAccountImages() error

func (*GormClient) SetupDB

func (gc *GormClient) SetupDB(addr string)

func (*GormClient) StoreAccountImage

func (gc *GormClient) StoreAccountImage(ctx context.Context, accountImage model.AccountImage) (model.AccountImage, error)

func (*GormClient) UpdateAccountImage

func (gc *GormClient) UpdateAccountImage(ctx context.Context, accountImage model.AccountImage) (model.AccountImage, error)

type IGormClient

type IGormClient interface {
	UpdateAccountImage(ctx context.Context, accountImage model.AccountImage) (model.AccountImage, error)
	StoreAccountImage(ctx context.Context, accountImage model.AccountImage) (model.AccountImage, error)
	QueryAccountImage(ctx context.Context, accountId string) (model.AccountImage, error)
	SetupDB(addr string)
	SeedAccountImages() error
	Check() bool
	Close()
}

Jump to

Keyboard shortcuts

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