[−][src]Struct fizyr_rpc::transport::StreamTransport
Transport layer for byte-stream sockets.
Implementations
impl<Stream> StreamTransport<Stream> where
Self: Transport,
[src]
Self: Transport,
pub fn new(stream: Stream, config: StreamConfig) -> Self
[src]
Create a new transport with custom configuration.
pub fn new_default(stream: Stream) -> Self
[src]
Create a new transport using the default configuration.
Trait Implementations
impl<'a, Address> Connect<'a, Address> for StreamTransport<UnixStream> where
Address: AsRef<Path> + 'a,
[src]
Address: AsRef<Path> + 'a,
type Future = Pin<Box<dyn Future<Output = Result<Self>> + 'a>>
The type of the future returned by Self::connect
.
fn connect(address: Address, config: Self::Config) -> Self::Future
[src]
impl<'a, Address> Connect<'a, Address> for StreamTransport<TcpStream> where
Address: ToSocketAddrs + 'a,
[src]
Address: ToSocketAddrs + 'a,
type Future = Pin<Box<dyn Future<Output = Result<Self>> + 'a>>
The type of the future returned by Self::connect
.
fn connect(address: Address, config: Self::Config) -> Self::Future
[src]
impl Transport for StreamTransport<UnixStream>
[src]
type Body = StreamBody
The body type for the messages.
type Config = StreamConfig
The configuration type for the transport.
type ReadHalf = ReadHalfType
The type of the read half of the transport.
type WriteHalf = WriteHalfType
The type of the write half of the transport.
fn split<'a>(
&'a mut self
) -> (StreamReadHalf<ReadHalf<'a>>, StreamWriteHalf<WriteHalf<'a>>)
[src]
&'a mut self
) -> (StreamReadHalf<ReadHalf<'a>>, StreamWriteHalf<WriteHalf<'a>>)
impl Transport for StreamTransport<TcpStream>
[src]
type Body = StreamBody
The body type for the messages.
type Config = StreamConfig
The configuration type for the transport.
type ReadHalf = ReadHalfType
The type of the read half of the transport.
type WriteHalf = WriteHalfType
The type of the write half of the transport.
fn split<'a>(
&'a mut self
) -> (StreamReadHalf<ReadHalf<'a>>, StreamWriteHalf<WriteHalf<'a>>)
[src]
&'a mut self
) -> (StreamReadHalf<ReadHalf<'a>>, StreamWriteHalf<WriteHalf<'a>>)
Auto Trait Implementations
impl<Stream> RefUnwindSafe for StreamTransport<Stream> where
Stream: RefUnwindSafe,
[src]
Stream: RefUnwindSafe,
impl<Stream> Send for StreamTransport<Stream> where
Stream: Send,
[src]
Stream: Send,
impl<Stream> Sync for StreamTransport<Stream> where
Stream: Sync,
[src]
Stream: Sync,
impl<Stream> Unpin for StreamTransport<Stream> where
Stream: Unpin,
[src]
Stream: Unpin,
impl<Stream> UnwindSafe for StreamTransport<Stream> where
Stream: UnwindSafe,
[src]
Stream: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,