Documentation
¶
Index ¶
- Variables
- func Register(server *client.Server)
- func Run(command string, args []string) error
- type AwayCmd
- type Command
- type CommandMetadata
- type ConnectCmd
- type EmptyCmd
- type ExitCmd
- type HelpCmd
- type JoinCmd
- type KickCmd
- type LogoCmd
- type MeCmd
- type MetadataTmpl
- type NamesCmd
- type NickCmd
- type NoticeCmd
- type PartCmd
- type PassCmd
- type QueryCmd
- type RawCmd
- type ShrugCmd
- type StatusCmd
- type TableFlipCmd
- type TopicCmd
- type VersionCmd
- type WhoCmd
- type WhoIsCmd
- type WindowCmd
Constants ¶
This section is empty.
Variables ¶
var ( // Commands list Commands []Command // Server global Server *client.Server // CurrentChannel name CurrentChannel = client.StatusChannel )
Functions ¶
Types ¶
type AwayCmd ¶ added in v0.9.2
type AwayCmd struct {
*MetadataTmpl
}
AwayCmd struct
func (*AwayCmd) Metadata ¶ added in v0.9.2
func (e *AwayCmd) Metadata() CommandMetadata
Metadata for AwayCmd command
type Command ¶
type Command interface {
Metadata() CommandMetadata
Exec(args []string) error
}
Command functions that a command must offer
type CommandMetadata ¶
type CommandMetadata interface {
Name() string
Args() string
Description() string
Aliases() []string
}
CommandMetadata functions that a command must offer
type ConnectCmd ¶
type ConnectCmd struct {
*MetadataTmpl
}
ConnectCmd struct
func (*ConnectCmd) Metadata ¶
func (e *ConnectCmd) Metadata() CommandMetadata
Metadata for conenct command
type EmptyCmd ¶
type EmptyCmd struct {
*MetadataTmpl
}
EmptyCmd struct
func (*EmptyCmd) Metadata ¶
func (e *EmptyCmd) Metadata() CommandMetadata
Metadata for empty command
type KickCmd ¶ added in v0.9.2
type KickCmd struct {
*MetadataTmpl
}
KickCmd struct
func (*KickCmd) Metadata ¶ added in v0.9.2
func (e *KickCmd) Metadata() CommandMetadata
Metadata for KickCmd command
type MetadataTmpl ¶
type MetadataTmpl struct {
// contains filtered or unexported fields
}
MetadataTmpl for commands
func (*MetadataTmpl) Description ¶
func (c *MetadataTmpl) Description() string
Description of command
type NamesCmd ¶
type NamesCmd struct {
*MetadataTmpl
}
NamesCmd struct
func (*NamesCmd) Metadata ¶
func (e *NamesCmd) Metadata() CommandMetadata
Metadata for names command
type NoticeCmd ¶
type NoticeCmd struct {
*MetadataTmpl
}
NoticeCmd struct
func (*NoticeCmd) Metadata ¶
func (e *NoticeCmd) Metadata() CommandMetadata
Metadata for notice command
type QueryCmd ¶
type QueryCmd struct {
*MetadataTmpl
}
QueryCmd struct
func (*QueryCmd) Metadata ¶
func (e *QueryCmd) Metadata() CommandMetadata
Metadata for query command
type ShrugCmd ¶
type ShrugCmd struct {
*MetadataTmpl
}
ShrugCmd struct
func (*ShrugCmd) Metadata ¶
func (e *ShrugCmd) Metadata() CommandMetadata
Metadata for shrug command
type StatusCmd ¶
type StatusCmd struct {
*MetadataTmpl
}
StatusCmd struct
func (*StatusCmd) Metadata ¶
func (e *StatusCmd) Metadata() CommandMetadata
Metadata for status command
type TableFlipCmd ¶
type TableFlipCmd struct {
*MetadataTmpl
}
TableFlipCmd struct
func (*TableFlipCmd) Exec ¶
func (e *TableFlipCmd) Exec(args []string) error
Exec for TableFlipCmd command
func (*TableFlipCmd) Metadata ¶
func (e *TableFlipCmd) Metadata() CommandMetadata
Metadata for TableFlipCmd command
type TopicCmd ¶
type TopicCmd struct {
*MetadataTmpl
}
TopicCmd struct
func (*TopicCmd) Metadata ¶
func (e *TopicCmd) Metadata() CommandMetadata
Metadata for TopicCmd command
type VersionCmd ¶
type VersionCmd struct {
*MetadataTmpl
}
VersionCmd struct
func (*VersionCmd) Metadata ¶
func (e *VersionCmd) Metadata() CommandMetadata
Metadata for version command