Documentation
¶
Overview ¶
botUtils provides a quicker method of calling the command and initializing all of the command instead of doing it manually one by one.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Initialize ¶
Initialize() assigns a linebot.Client pointer to a Bot variable, making it usable for the handler. It also initialize other things such as creating a new weather instance, setting a random seed, and reading ball8 choices text file. In this way, only this method of initialization is necessary to make the bot work.
Types ¶
type Caller ¶
Caller provides a list of executable command function which simplifies commandHandler's process.
var Call Caller
func Execute ¶
func Execute() *Caller
Execute() returns a Caller, which then provides a list of executable command function.
func (*Caller) SetReplyToken ¶
Sets a replytoken to ensure proper replying. NOTICE: This token must be refreshed everytime it is possible to ensure proper replying.
Directories
¶
Path | Synopsis |
---|---|
Provides a gateway for the handler into handling a command (message) sent by an user.
|
Provides a gateway for the handler into handling a command (message) sent by an user. |
commands
|
|
ball8
Provides a "yes/no" type reply when executed.
|
Provides a "yes/no" type reply when executed. |
coin
Provides the result of a flipping coin.
|
Provides the result of a flipping coin. |
dice
Provides the result of a rolling dice.
|
Provides the result of a rolling dice. |
latex
Provides a quick way into parsing a message into the chat into a latex equation (generally math equation).
|
Provides a quick way into parsing a message into the chat into a latex equation (generally math equation). |
movies
Provides a summary of a movie based on themoviedb.org
|
Provides a summary of a movie based on themoviedb.org |
quotes
Provides a qod of the specified category (http://quotes.rest/qod/categories to see the list of available public categories).
|
Provides a qod of the specified category (http://quotes.rest/qod/categories to see the list of available public categories). |
weather
Provides a quick weather lookup.
|
Provides a quick weather lookup. |
Provides a simple way to handle a potential command from a message sent by a user.
|
Provides a simple way to handle a potential command from a message sent by a user. |
Provides a random integer generator.
|
Provides a random integer generator. |
Provides a simple reply handler to the user.
|
Provides a simple reply handler to the user. |