Documentation ¶
Overview ¶
Package cats is a plugin that queries some cat API's and returns responses. It queries a cat fact API and a cat image/gif API
Index ¶
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Plugin ¶
type Plugin struct{}
Plugin ...
func (Plugin) HandleMessage ¶
HandleMessage is responsible for handling the incoming message and returning a response based on the message provides
Example ¶
fmt.Printf("%q\n", reCats.FindStringSubmatch("!cat")) fmt.Printf("%q\n", reCatsType.FindStringSubmatch("!cat fact")[1]) fmt.Printf("%q\n", reCatsType.FindStringSubmatch("!cat gif")) fmt.Printf("%q\n", reCats.FindStringSubmatch("cat"))
Output: ["!cat"] "fact" ["!cat gif" "gif"] []
Click to show internal directories.
Click to hide internal directories.