Documentation
¶
Index ¶
- type Bot
- func Classic(local, server string, name string) *Bot
- func New(local, server, name string, config Config) *Bot
- func WithLogin(local, server string, name string, user string, password string) *Bot
- func WithLoginTLS(local, server string, name string, user string, password string, ...) *Bot
- func WithTLS(local, server string, name string, tlsConfig *tls.Config) *Bot
- type Config
- type Handler
- type HandlerFunc
- type Sender
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Bot ¶
type Bot struct {
LAddr *net.TCPAddr
RAddr *net.TCPAddr
Server string
OriginalName string
Config Config
Data chan *irc.Message
Sender Sender
// contains filtered or unexported fields
}
Bot contains all of the information necessary to run a single IRC client
func Classic ¶
Classic creates an instance of ircx poised to connect to the given server with the given IRC name.
func WithLogin ¶
WithLogin creates an instance with the specified server, name user and password for the IRC server
func WithLoginTLS ¶
func WithLoginTLS(local, server string, name string, user string, password string, tlsConfig *tls.Config) *Bot
WithLoginTLS creates an instance with the specified information + TLS config
func WithTLS ¶
WithTLS creates an instance of ircx poised to connect to the given server using TLS with the given IRC name.
func (*Bot) HandleFunc ¶
HandleFunc registers the handler function for the given command
func (*Bot) HandleLoop ¶
func (b *Bot) HandleLoop()
HandleLoop reads from the ReadLoop channel and initiates a handler check for every message it recieves.
type HandlerFunc ¶
HandlerFunc is a type that represents the method necessary to implement Handler