bot

package
v0.0.0-...-8bebc79 Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2016 License: MIT Imports: 1 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bot

type Bot struct {
	Cmds chan Cmd
	Msgs chan Msg
}

func New

func New() Bot

func (Bot) Errorf

func (b Bot) Errorf(format string, v ...interface{}) State

func (Bot) Get

func (b Bot) Get() Msg

func (Bot) Init

func (b Bot) Init() State

func (Bot) Run

func (b Bot) Run(init State)

func (Bot) Send

func (b Bot) Send(cmd Cmd)

type Bottable

type Bottable interface {
	Init() State
	Send(Cmd)
	Get() Msg
}

type Cmd

type Cmd string

type Msg

type Msg string

type State

type State func() State

Jump to

Keyboard shortcuts

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