Skip to main content

udp/
lib.rs

1//! udp
2//!
3//! A lightweight and efficient Rust library for
4//! building UDP servers with request-response handling.
5
6mod common;
7mod config;
8mod context;
9mod handler;
10mod request;
11mod response;
12mod server;
13mod socket;
14mod utils;
15
16pub use {config::*, context::*, request::*, response::*, server::*, socket::*, utils::*};
17
18pub use tokio;
19
20use {common::*, handler::*};
21
22use std::{
23    any::Any,
24    collections::HashMap,
25    error::Error as StdError,
26    fmt::{self, Display},
27    future::Future,
28    net::{IpAddr, Ipv4Addr, SocketAddr, SocketAddrV4},
29    panic::set_hook,
30    pin::Pin,
31    sync::Arc,
32};
33
34use tokio::{
35    net::UdpSocket,
36    sync::{MutexGuard, RwLock, RwLockReadGuard, RwLockWriteGuard},
37};