[][src]Module vk_bot::core

The Core struct, supported Events, and handler/tester types.

Structs

Core

Core accepts user-defined handlers, and invokes them when needed. Note that only one handler (the first found, according to the Core::on docs) is called for a given message.

Handler

Handler's Fn should handle the message/event using the given &mut Context, and return it back when finished.

Tester

Tester's Fn should return whether a payload string (you to set the payload in Keyboard Buttons) is interesting for a handler to handle.

Enums

Event

Events that are supported for event handlers.

Type Definitions

HandlerInner

Inner type of Handler.

TesterInner

Inner type of Tester.