api

package
v0.0.0-...-f910b46 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2024 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNotExist = errors.New("[>] api does not exist")

Functions

This section is empty.

Types

type FindAllPage

type FindAllPage struct {
	Size   uint64
	Offset uint64
}

type FindResult

type FindResult struct {
	Apis   []model.Api
	Cursor uint64
}

type PostgresRepo

type PostgresRepo struct {
}

type RedisRepo

type RedisRepo struct {
	Client *redis.Client
}

func (*RedisRepo) DeleteByID

func (r *RedisRepo) DeleteByID(ctx context.Context, id uint64) error

func (*RedisRepo) FindAll

func (r *RedisRepo) FindAll(ctx context.Context, page FindAllPage) (FindResult, error)

func (*RedisRepo) FindByID

func (r *RedisRepo) FindByID(ctx context.Context, id uint64) (model.Api, error)

func (*RedisRepo) Insert

func (r *RedisRepo) Insert(ctx context.Context, api model.Api) error

func (*RedisRepo) Update

func (r *RedisRepo) Update(ctx context.Context, api model.Api) error

Jump to

Keyboard shortcuts

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