card

package
v0.0.0-...-0158116 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2024 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseCard

type BaseCard struct {
	Ctx        context.Context             `json:"-"`
	HandlerMap map[string]handler.IHandler `json:"-"`
}

func (*BaseCard) GetHandler

func (b *BaseCard) GetHandler(name string) (handler handler.IHandler, err error)

func (*BaseCard) Input

func (b *BaseCard) Input(ctx context.Context)

func (*BaseCard) Register

func (b *BaseCard) Register(handler handler.IHandler)

type BigCard

type BigCard struct {
	BaseCard
	Name string `json:"name"`
}

func NewBigCard

func NewBigCard() *BigCard

func (*BigCard) GetCardType

func (hc *BigCard) GetCardType() string

func (*BigCard) Output

func (hc *BigCard) Output() string

type ICard

type ICard interface {
	GetCardType() string
	Input(ctx context.Context)
	Output() string
	Register(handler handler.IHandler)
	GetHandler(name string) (handler handler.IHandler, err error)
}

type SmallCard

type SmallCard struct {
	BaseCard
	Name string `json:"name"`
}

func NewSmallCard

func NewSmallCard() *SmallCard

func (*SmallCard) GetCardType

func (sm *SmallCard) GetCardType() string

func (*SmallCard) Output

func (sm *SmallCard) Output() string

Jump to

Keyboard shortcuts

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