#irc-client #future #irc-v3 #tokio #ping #stream #client-server

tokio-irc-client

IRCv3 compatible client library using tokio and futures

4 releases

Uses old Rust 2015

0.2.1 May 14, 2017
0.2.0 May 14, 2017
0.1.1 Mar 27, 2017
0.1.0 Mar 26, 2017

#9 in #irc-v3

46 downloads per month

Apache-2.0/MIT

15KB
239 lines

tokio-irc-client

IRCv3 client library for Rust built on tokio and futures.

Build Status Build status Crates

Usage

License

tokio-irc-client is distributed under the terms of both the MIT license and the Apache License (Version 2.0).

See LICENSE-APACHE, and LICENSE-MIT for details.


lib.rs:

Low-level futures based IRC client library for Rust

Tihs library is an implementation of the IRCv3 protocol which uses futures to provide asynchronous processing of incoming and outgoing messages between the client and the server.

This library makes extensive use of tokio and futures to provide asynchronous handling of IRC via the Future, Stream, and Sink traits. This allows for the usage of combinators on the stream of incoming messages to allow for easy processing of messages.

The abstraction provided by this library is currently very minimal. It currently handles connecting to a remote IRC server either through unencypted sockets or TLS encrypted sockets. It internally handles the parsing of IRC messages and has several helper functions to build IRC messages to be sent to the server. It also handles responding to PING requests from the server and will timeout the connection if no PINGs are received after a certain duration (currently 10 minutes).

The main type in this library is the Cient struct, which provides the ability to connect to a remote host. The various connection methods on this type return a future, that when complete, provides a stream of IRC messages that can also be written to. It is possible to call the split function on this stream to get a Stream or incoming IRC messages and Sink for for sending messages to the server.

Dependencies

~8–17MB
~211K SLoC