schema

package
v0.0.0-...-571f2ff Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2021 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Action

type Action int
const (
	STOP Action = iota
	CONTINUE
	SKIP
)

type Buffer

type Buffer interface {
	SendBack([]byte)
	GetBackData() []byte
}

type Carpool

type Carpool interface {
	Set(interface{}, interface{})
	Get(interface{}) (value interface{}, ok bool)
}

type Container

type Container interface {
	Init() errors.Error
	FInit() errors.Error
	Add([]Plugin) errors.Error
	Remove(string) errors.Error
	Get(...string) ([]Plugin, errors.Error)
}

type Loader

type Loader interface {
	Init() errors.Error
	FInit() errors.Error
	Load(...string) ([]Plugin, errors.Error)
}

type Logger

type Logger interface {
	Logger() log.Logger
}

type NewPlugin

type NewPlugin = func(*viper.Viper) (Plugin, errors.Error)
var NewPluginObj NewPlugin

type Plugin

type Plugin interface {
	Name() string
	Init() errors.Error
	FInit() errors.Error
	Interest(msg *proto.Msg, tools PluginTools) (Action, errors.Error)
	PreProcess(msg *proto.Msg, tools PluginTools) (Action, errors.Error)
	Process(msg *proto.Msg, tools PluginTools) (Action, errors.Error)
	PostProcess(msg *proto.Msg, tools PluginTools) (Action, errors.Error)
}

type PluginTools

type PluginTools interface {
	Buffer
	Logger
	Carpool
}

Jump to

Keyboard shortcuts

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