pub trait AnySocket<'a> {
// Required methods
fn upcast(self) -> Socket<'a>;
fn downcast<'c>(socket: &'c Socket<'a>) -> Option<&'c Self>
where Self: Sized;
fn downcast_mut<'c>(socket: &'c mut Socket<'a>) -> Option<&'c mut Self>
where Self: Sized;
}
Expand description
A conversion trait for network sockets.