api

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2024 License: Apache-2.0 Imports: 17 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddBanRequest

type AddBanRequest struct {
	Name      string    `json:"name"`
	ExpiredAt time.Time `json:"expiredAt"`
}

type Ban

type Ban struct {
	ID        string    `json:"id"`
	Name      string    `json:"name"`
	ExpiredAt time.Time `json:"expiredAt"`
}

type BansDAO

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

func NewBansDAO

func NewBansDAO() *BansDAO

func (*BansDAO) AddBan

func (b *BansDAO) AddBan(ctx context.Context, ban Ban) error

func (*BansDAO) DeleteBan added in v1.1.2

func (b *BansDAO) DeleteBan(ctx context.Context, banID string) error

func (*BansDAO) GetBan

func (b *BansDAO) GetBan(ctx context.Context, banID string) (Ban, error)

type WebService

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

func InitWebService

func InitWebService(basePath string) *WebService

func (*WebService) Serve

func (w *WebService) Serve()

Jump to

Keyboard shortcuts

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