app

package
v1.0.5 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App added in v1.0.5

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

func New added in v1.0.5

func New(ctx *config.Context) *App

func (*App) Route added in v1.0.5

func (a *App) Route(r *wkhttp.WKHttp)

type DB

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

DB DB

type IService

type IService interface {
	// GetApp 获取app
	GetApp(appID string) (*Resp, error)
	// 创建app
	CreateApp(r Req) (*Resp, error)
}

IService 服务接口

func NewService

func NewService(ctx *config.Context) IService

NewService NewService

type Req

type Req struct {
	AppID string
}

func (Req) Check

func (r Req) Check() error

type Resp

type Resp struct {
	AppID   string
	AppKey  string
	AppName string
	Status  Status
}

type Service

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

Service app服务

func (*Service) CreateApp

func (s *Service) CreateApp(r Req) (*Resp, error)

CreateApp 创建APP 幂等

func (*Service) GetApp

func (s *Service) GetApp(appID string) (*Resp, error)

GetApp 获取APP信息

type Status

type Status int

Status app状态

const (
	// StatusDisable app被禁用
	StatusDisable Status = iota
	// StatusEnable app被启用
	StatusEnable
)

func (Status) Int

func (s Status) Int() int

func (Status) String added in v1.0.5

func (s Status) String() string

Jump to

Keyboard shortcuts

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