cmd

package
v0.0.0-...-7f3434b Latest Latest
Warning

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

Go to latest
Published: Jan 12, 2017 License: GPL-3.0, GPL-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const DATE_FORMAT = "02/01/2006 15:04:05"

Variables

View Source
var ChatUserID string

Functions

func Run

func Run(bot *tgbotapi.BotAPI, chatMessage *tgbotapi.Message) error

Types

type Base

type Base struct {
}

Base abstract command

type BaseCmd

type BaseCmd interface {
	Run(bot *tgbotapi.BotAPI, chatMessage *tgbotapi.Message) error
}

Command interface

type HelpCmd

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

'/help' command

func (*HelpCmd) Run

func (help *HelpCmd) Run(bot *tgbotapi.BotAPI, chatMessage *tgbotapi.Message) error

type NotCmd

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

not a command message

func (*NotCmd) Run

func (notCmd *NotCmd) Run(bot *tgbotapi.BotAPI, chatMessage *tgbotapi.Message) error

type RemindCmd

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

'/remind' command

func NewRemindCmd

func NewRemindCmd() *RemindCmd

func (*RemindCmd) GetStep

func (remind *RemindCmd) GetStep() int

func (*RemindCmd) Run

func (remind *RemindCmd) Run(bot *tgbotapi.BotAPI, chatMessage *tgbotapi.Message) error

type RemindStep

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

func NewRemindStep

func NewRemindStep(parent *RemindCmd) *RemindStep

func (*RemindStep) Run

func (step *RemindStep) Run(bot *tgbotapi.BotAPI, chatMessage *tgbotapi.Message) error

type StartCmd

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

'/start' command

func (*StartCmd) Run

func (start *StartCmd) Run(bot *tgbotapi.BotAPI, chatMessage *tgbotapi.Message) error

type UnknownCmd

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

'unknown' command

func (*UnknownCmd) Run

func (unknown *UnknownCmd) Run(bot *tgbotapi.BotAPI, chatMessage *tgbotapi.Message) error

Jump to

Keyboard shortcuts

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