http_type/stream/struct.rs
1use crate::*;
2
3/// A wrapper around `Arc<RwLock<TcpStream>>`.
4///
5/// `ArcRwLockStream` provides shared, thread-safe access to a `TcpStream`
6/// using an atomic reference counter (`Arc`) combined with a read-write lock (`RwLock`).
7/// It is primarily used to safely share the stream across asynchronous tasks.
8///
9/// # Fields
10/// - `0`: The inner `Arc<RwLock<TcpStream>>` stream.
11#[derive(Clone, Debug, Getter)]
12pub struct ArcRwLockStream(#[get(pub(super))] pub(super) ArcRwLock<TcpStream>);