2022-12-30 10:21:41 +08:00
|
|
|
package plugin
|
|
|
|
|
|
|
|
// Info presents the plugin information
|
|
|
|
type Info struct {
|
2023-02-21 17:27:14 +08:00
|
|
|
Name Translator
|
2023-01-10 16:43:42 +08:00
|
|
|
SlugName string
|
2023-02-21 17:27:14 +08:00
|
|
|
Description Translator
|
2022-12-30 10:21:41 +08:00
|
|
|
Author string
|
|
|
|
Version string
|
2023-03-02 11:03:24 +08:00
|
|
|
Link string
|
2022-12-30 10:21:41 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
// Base is the base plugin
|
|
|
|
type Base interface {
|
|
|
|
// Info returns the plugin information
|
|
|
|
Info() Info
|
|
|
|
}
|
|
|
|
|
|
|
|
var (
|
|
|
|
// CallBase is a function that calls all registered base plugins
|
|
|
|
CallBase,
|
2023-01-10 16:43:42 +08:00
|
|
|
registerBase = MakePlugin[Base](true)
|
2022-12-30 10:21:41 +08:00
|
|
|
)
|