Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type TomlBotConfigProvider ¶
type TomlBotConfigProvider struct {
// contains filtered or unexported fields
}
TomlBotConfigProvider is a provider for bot configurations stored in a TOML file
func ParseTomlBotConfig ¶
func ParseTomlBotConfig(rd io.Reader) (*TomlBotConfigProvider, error)
ParseTomlBotConfig a provided reader and return the config if successful
func ParseTomlBotConfigFromFile ¶
func ParseTomlBotConfigFromFile(fileName string) (*TomlBotConfigProvider, error)
ParseTomlBotConfigFromFile and return the config if successful
func (*TomlBotConfigProvider) GetAllBotConfigs ¶
func (c *TomlBotConfigProvider) GetAllBotConfigs() botconfig.BotConfigs
GetAllBotConfigs returns all known bot configurations
func (*TomlBotConfigProvider) GetAllEnabledBotIDs ¶
func (c *TomlBotConfigProvider) GetAllEnabledBotIDs() (botIDs []string)
GetAllEnabledBotIDs returns only bot IDs for bots which are enabled
func (*TomlBotConfigProvider) GetBotConfig ¶
func (c *TomlBotConfigProvider) GetBotConfig(id string) (botconfig.BotConfig, error)
GetBotConfig returns a config for the given ID if it exists
Click to show internal directories.
Click to hide internal directories.