demo

package
v0.0.0-...-366d18e Latest Latest
Warning

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

Go to latest
Published: Dec 14, 2021 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const DemoKey = "hxk:demo"

DemoKey Demo服务的key

Variables

This section is empty.

Functions

func NewService

func NewService(params ...interface{}) (interface{}, error)

NewService 初始化实例的方法

Types

type DemoProvider

type DemoProvider struct {
	framework.ServiceProvider
	// contains filtered or unexported fields
}

func (*DemoProvider) Boot

func (sp *DemoProvider) Boot(c framework.Container) error

func (*DemoProvider) IsDefer

func (sp *DemoProvider) IsDefer() bool

func (*DemoProvider) Name

func (sp *DemoProvider) Name() string

func (*DemoProvider) Params

func (sp *DemoProvider) Params(c framework.Container) []interface{}

func (*DemoProvider) Register

type IService

type IService interface {
	GetAllStudent() []Student
}

IService 服务的接口

type Service

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

func (*Service) GetAllStudent

func (s *Service) GetAllStudent() []Student

type Student

type Student struct {
	ID   int
	Name string
}

Jump to

Keyboard shortcuts

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