本文整理汇总了Golang中github.com/justinkim/yullibot/irc.Message.Subcommand方法的典型用法代码示例。如果您正苦于以下问题:Golang Message.Subcommand方法的具体用法?Golang Message.Subcommand怎么用?Golang Message.Subcommand使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类github.com/justinkim/yullibot/irc.Message
的用法示例。
在下文中一共展示了Message.Subcommand方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Golang代码示例。
示例1: Process
func (avalon *AvalonCommand) Process(bot *models.Bot, msg *irc.Message) {
if !models.CommandTriggered(avalon, msg) {
return
}
subcommand := msg.Subcommand()
switch subcommand {
case "disable":
avalon.DoDisable(bot, msg)
case "enable":
avalon.DoEnable(bot, msg)
case "help", "":
avalon.DoHelp(bot, msg)
case "implode":
avalon.DoImplode(bot, msg)
case "info":
avalon.DoInfo(bot, msg)
case "init":
avalon.DoInit(bot, msg)
case "join":
avalon.DoJoin(bot, msg)
case "start":
avalon.DoStart(bot, msg)
case "status":
avalon.DoStatus(bot, msg)
}
}