pluginframework

package
v0.0.0-...-2fdac85 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2017 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var RegisteredPlugins = map[string]BotPlugin{}

Functions

func DecodeJson

func DecodeJson(url string, f func(io.ReadCloser) bool) (bool, error)

func Register

func Register(botPlugin BotPlugin)

func SaveAudio

func SaveAudio(url string) (string, error)

func SaveImage

func SaveImage(url string) (string, error)

func SaveSticker

func SaveSticker(url string) (string, error)

func SaveVideo

func SaveVideo(url string) (string, error)

func SendAudio

func SendAudio(url string, message telebot.Message, bot *telebot.Bot) error

func SendPhoto

func SendPhoto(url string, message telebot.Message, bot *telebot.Bot) error

func SendSticker

func SendSticker(url string, message telebot.Message, bot *telebot.Bot) error

func SendVideo

func SendVideo(url string, message telebot.Message, bot *telebot.Bot) error

func UrlExt

func UrlExt(url string) string

Types

type BotPlugin

type BotPlugin interface {
	OnStart()
	OnStop()
	Run(telebot.Message)
	Command() string
	PluginId() string
	Description() string
}

Jump to

Keyboard shortcuts

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