[][src]Crate twitchchat

This crate provides a way to interface with Twitch's chat.

Along with the messages as Rust types, it provides methods for sending messages.


Modules

channel

Simple async/sync channels used in various parts of this crate.

color

Color types associated with Twitch.

commands

Provides Encodable commands.

connector

Asynchronous connectors for various runtimes. This module lets you choose which runtime you want to use.

irc

IRC message parsing.

messages

Twitch messages that can be parsed from IrcMessage, or subscribed to from the Dispatcher

runner

A set of runners for managing a 'main loop'

writer

A set of writers

Structs

AsyncDecoder

A decoder which'll let you read IrcMessages from an futures::io::Read instance

AsyncEncoder

An asynchronous encoder.

Badge

Badges attached to a message

Decoder

A decoder which'll let you read IrcMessages from an std::io::Read instance

Emotes

Emotes are little pictograms used in-line in Twitch messages

Encoder

A synchronous encoder

IrcMessage

A raw irc message @tags :prefix COMMAND args :data\r\n

Receiver

Async and Sync MPMP Receiver.

Sender

Async and Sync MPMP Sender.

StrIndex

An index into a MaybeOwned (type-aliased to Str for this crate)

TagIndices

Pre-computed tag indices

Tags

Tags are IRCv3 message tags. Twitch uses them extensively.

UserConfig

User configuration for 'registering' with Twitch

UserConfigBuilder

Builder for making a UserConfig

Enums

BadgeKind

The kind of the badges that are associated with messages.

Capability

Capability used to enable extra functionality with the protocol

DecodeError

An error produced by a Decoder.

InvalidMessage

An invalid message was either provided, or could not be parsed

RateClass

A preset number of tokens as described by Twitch

Str

A str type that can either be in a borrowed state, or an owned state.

UserConfigError

User config error returned by the UserConfigBuilder

Constants

ANONYMOUS_LOGIN

An anonymous login.

TWITCH_IRC_ADDRESS

The Twitch IRC address for non-TLS connections

TWITCH_IRC_ADDRESS_TLS

The Twitch IRC address for TLS connections

TWITCH_TLS_DOMAIN

A TLS domain for Twitch

TWITCH_WS_ADDRESS

The Twitch WebSocket address for non-TLS connections

TWITCH_WS_ADDRESS_TLS

The Twitch WebSocket address for TLS connections

Traits

Encodable

A trait to allow writing messags to any std::io::Write implementation

FromIrcMessage

A trait to convert an IrcMessage into Self.

IntoIrcMessage

A trait to convert a Self into an IrcMessage

IntoOwned

Converts a 'borrowed' type into an owned type. e.g. 'a to 'static

PrivmsgExt

Extensions to the Privmsg message type

Validator

This trait is provided as an easy way of defining your own custom events.

Type Definitions

BadgeInfo

Metadata to the chat badges

BoxedFuture

A boxed Future that is Send + Sync