[][src]Struct capnp_rpc::twoparty::VatNetwork

pub struct VatNetwork<T> where
    T: AsyncRead + 'static + Unpin
{ /* fields omitted */ }

A vat networks with two parties, the client and the server.

Implementations

impl<T> VatNetwork<T> where
    T: AsyncRead + Unpin
[src]

pub fn new<U>(
    input_stream: T,
    output_stream: U,
    side: Side,
    receive_options: ReaderOptions
) -> VatNetwork<T> where
    U: AsyncWrite + 'static + Unpin
[src]

Creates a new two-party vat network that will receive data on input_stream and send data on output_stream.

side indicates whether this is the client or the server side of the connection. This has no effect on the data sent over the connection; it merely exists so that RpcNetwork::bootstrap knows whether to return the local or the remote bootstrap capability. VatId parameters like this one will make more sense once we have vat networks with more than two parties.

The options in receive_options will be used when reading the messages that come in on input_stream.

Trait Implementations

impl<T> VatNetwork<Side> for VatNetwork<T> where
    T: AsyncRead + Unpin
[src]

Auto Trait Implementations

impl<T> !RefUnwindSafe for VatNetwork<T>

impl<T> !Send for VatNetwork<T>

impl<T> !Sync for VatNetwork<T>

impl<T> Unpin for VatNetwork<T>

impl<T> !UnwindSafe for VatNetwork<T>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.