Struct distant_core::DistantServer [−][src]
pub struct DistantServer { /* fields omitted */ }
Expand description
Represents a server that listens for requests, processes them, and sends responses
Implementations
Bind to an IP address and port from the given range, taking an optional shutdown duration that will shutdown the server if there is no active connection after duration
pub fn initialize<T, U, S>(stream: S, opts: DistantServerOptions) -> Self where
T: DataStream + Send + 'static,
U: Codec + Send + 'static,
S: Stream<Item = Transport<T, U>> + Send + Unpin + 'static,
pub fn initialize<T, U, S>(stream: S, opts: DistantServerOptions) -> Self where
T: DataStream + Send + 'static,
U: Codec + Send + 'static,
S: Stream<Item = Transport<T, U>> + Send + Unpin + 'static,
Initialize a distant server using the provided listener