Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Conf ¶
type Conf struct { Pastebin PastebinCreds Twitch TwitchCreds Stats Stats Admins []string Hello string Prefix string Verified bool }
Conf is a meta structure containing all nedded configuration for a gambling instance
type Gambling ¶
type Gambling struct { // Config from yaml file Config Conf // Twitch client Twitch *twitch.Client // Vote CurrentVote *Vote // whisper rate limiter WhispRL *rate.Limiter // Warning rate limiter WarnRL *rate.Limiter }
Gambling is a meta structure containing all the stuff needed by a Gambling instance
func NewGambling ¶
NewGambling func create a new Gambling struct
type PastebinCreds ¶
type PastebinCreds struct {
Key string
}
PastebinCreds is a structure contaning all credentials for Pastebin
type Statistics ¶
Statistics is a struct containing generated stats for a given vote
func NewStatistics ¶
func NewStatistics(votes *Vote) Statistics
NewStatistics if used to transform a vote into a statistics struct
type Stats ¶
type Stats struct { // Base dir path used to store generated files Dir string }
Stats is a structure containing config related to stats generation
type TwitchCreds ¶
TwitchCreds is a structure containing all credenials for Twitch
type Vote ¶
type Vote struct { IsOpen bool Possibilities []string Votes map[string]string Acks Acks Winners []string }
Vote is a structure handling all voting params and status
type VoteAck ¶
type VoteAck struct { Username string // contains filtered or unexported fields }
VoteAck is a struct containing vote acknolegment send later if rate limit is reached
func NewVoteAck ¶
NewVoteAck is used to init a VoteAck struct