mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-08-26 00:00:16 +02:00
This also bumps a number of sub crates: * tokio-executor (0.1.3) * tokio-io (0.1.8) * tokio-reactor (0.1.4) * tokio-threadpool (0.1.6) * tokio-timer (0.2.6) * tokio-udp (0.1.2)
41 lines
1.2 KiB
Rust
41 lines
1.2 KiB
Rust
#![doc(html_root_url = "https://docs.rs/tokio-tcp/0.1.2")]
|
|
#![deny(missing_docs, warnings, missing_debug_implementations)]
|
|
|
|
//! UDP bindings for `tokio`.
|
|
//!
|
|
//! This module contains the UDP networking types, similar to the standard
|
|
//! library, which can be used to implement networking protocols.
|
|
//!
|
|
//! The main struct for UDP is the [`UdpSocket`], which represents a UDP socket.
|
|
//! Reading and writing to it can be done using futures, which return the
|
|
//! [`RecvDgram`] and [`SendDgram`] structs respectively.
|
|
//!
|
|
//! For convenience it's also possible to convert raw datagrams into higher-level
|
|
//! frames.
|
|
//!
|
|
//! [`UdpSocket`]: struct.UdpSocket.html
|
|
//! [`RecvDgram`]: struct.RecvDgram.html
|
|
//! [`SendDgram`]: struct.SendDgram.html
|
|
//! [`UdpFramed`]: struct.UdpFramed.html
|
|
//! [`framed`]: struct.UdpSocket.html#method.framed
|
|
|
|
extern crate bytes;
|
|
#[macro_use]
|
|
extern crate futures;
|
|
extern crate mio;
|
|
#[macro_use]
|
|
extern crate log;
|
|
extern crate tokio_codec;
|
|
extern crate tokio_io;
|
|
extern crate tokio_reactor;
|
|
|
|
mod frame;
|
|
mod socket;
|
|
mod send_dgram;
|
|
mod recv_dgram;
|
|
|
|
pub use self::frame::UdpFramed;
|
|
pub use self::socket::UdpSocket;
|
|
pub use self::send_dgram::SendDgram;
|
|
pub use self::recv_dgram::RecvDgram;
|