pub enum Resource {
Port(Port),
Os(OsResource),
}
Expand description
A resource that can be sent via a port.
Variants§
Port(Port)
Another port.
Os(OsResource)
An OS resource (file descriptor, Windows handle, or socket).
Trait Implementations§
source§impl MessageDecode<'_, Message, Resource> for MessageEncoder
impl MessageDecode<'_, Message, Resource> for MessageEncoder
source§fn read_message(
item: &mut InplaceOption<'_, Message>,
reader: MessageReader<'_, '_, Resource>,
) -> Result<(), Error>
fn read_message( item: &mut InplaceOption<'_, Message>, reader: MessageReader<'_, '_, Resource>, ) -> Result<(), Error>
Reads a message into
item
.source§impl MessageEncode<Box<dyn DynSerializeMessage>, Resource> for MessageEncoder
impl MessageEncode<Box<dyn DynSerializeMessage>, Resource> for MessageEncoder
source§fn write_message(
item: Box<dyn DynSerializeMessage>,
writer: MessageWriter<'_, '_, Resource>,
)
fn write_message( item: Box<dyn DynSerializeMessage>, writer: MessageWriter<'_, '_, Resource>, )
Writes
item
as a message.source§fn compute_message_size(
item: &mut Box<dyn DynSerializeMessage>,
sizer: MessageSizer<'_>,
)
fn compute_message_size( item: &mut Box<dyn DynSerializeMessage>, sizer: MessageSizer<'_>, )
Computes the size of
item
as a message. Read moresource§impl MessageEncode<Message, Resource> for MessageEncoder
impl MessageEncode<Message, Resource> for MessageEncoder
source§fn write_message(item: Message, writer: MessageWriter<'_, '_, Resource>)
fn write_message(item: Message, writer: MessageWriter<'_, '_, Resource>)
Writes
item
as a message.source§fn compute_message_size(item: &mut Message, sizer: MessageSizer<'_>)
fn compute_message_size(item: &mut Message, sizer: MessageSizer<'_>)
Computes the size of
item
as a message. Read moresource§impl<'encoding> StructDecodeMetadata<'encoding, Resource> for CancelContext
impl<'encoding> StructDecodeMetadata<'encoding, Resource> for CancelContext
source§const DECODERS: &'static [ErasedDecoderEntry] = _
const DECODERS: &'static [ErasedDecoderEntry] = _
The list of decoder vtables.
source§impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for Cell<T>
impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for Cell<T>
source§const DECODERS: &'static [ErasedDecoderEntry] = _
const DECODERS: &'static [ErasedDecoderEntry] = _
The list of decoder vtables.
source§impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for CellUpdater<T>
impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for CellUpdater<T>
source§const DECODERS: &'static [ErasedDecoderEntry] = _
const DECODERS: &'static [ErasedDecoderEntry] = _
The list of decoder vtables.
source§impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for MpscReceiver<T>where
T: MeshField,
impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for MpscReceiver<T>where
T: MeshField,
source§const DECODERS: &'static [ErasedDecoderEntry] = _
const DECODERS: &'static [ErasedDecoderEntry] = _
The list of decoder vtables.
source§impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for MpscSender<T>where
T: MeshField,
impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for MpscSender<T>where
T: MeshField,
source§const DECODERS: &'static [ErasedDecoderEntry] = _
const DECODERS: &'static [ErasedDecoderEntry] = _
The list of decoder vtables.
source§impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for OneshotReceiver<T>where
T: MeshField,
impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for OneshotReceiver<T>where
T: MeshField,
source§const DECODERS: &'static [ErasedDecoderEntry] = _
const DECODERS: &'static [ErasedDecoderEntry] = _
The list of decoder vtables.
source§impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for OneshotSender<T>where
T: MeshField,
impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for OneshotSender<T>where
T: MeshField,
source§const DECODERS: &'static [ErasedDecoderEntry] = _
const DECODERS: &'static [ErasedDecoderEntry] = _
The list of decoder vtables.
source§impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for Receiver<T>where
T: MeshField,
impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for Receiver<T>where
T: MeshField,
source§const DECODERS: &'static [ErasedDecoderEntry] = _
const DECODERS: &'static [ErasedDecoderEntry] = _
The list of decoder vtables.
source§impl<'encoding, I, R> StructDecodeMetadata<'encoding, Resource> for Rpc<I, R>
impl<'encoding, I, R> StructDecodeMetadata<'encoding, Resource> for Rpc<I, R>
source§const DECODERS: &'static [ErasedDecoderEntry] = _
const DECODERS: &'static [ErasedDecoderEntry] = _
The list of decoder vtables.
source§impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for Sender<T>where
T: MeshField,
impl<'encoding, T> StructDecodeMetadata<'encoding, Resource> for Sender<T>where
T: MeshField,
source§const DECODERS: &'static [ErasedDecoderEntry] = _
const DECODERS: &'static [ErasedDecoderEntry] = _
The list of decoder vtables.
source§impl<'encoding> StructDecodeMetadata<'encoding, Resource> for WritePipe
impl<'encoding> StructDecodeMetadata<'encoding, Resource> for WritePipe
source§const DECODERS: &'static [ErasedDecoderEntry] = _
const DECODERS: &'static [ErasedDecoderEntry] = _
The list of decoder vtables.
source§impl StructEncodeMetadata<Resource> for CancelContext
impl StructEncodeMetadata<Resource> for CancelContext
source§const ENCODERS: &'static [ErasedEncoderEntry] = _
const ENCODERS: &'static [ErasedEncoderEntry] = _
The list of encoder vtables.
source§impl<T> StructEncodeMetadata<Resource> for Cell<T>
impl<T> StructEncodeMetadata<Resource> for Cell<T>
source§const ENCODERS: &'static [ErasedEncoderEntry] = _
const ENCODERS: &'static [ErasedEncoderEntry] = _
The list of encoder vtables.
source§impl<T> StructEncodeMetadata<Resource> for CellUpdater<T>
impl<T> StructEncodeMetadata<Resource> for CellUpdater<T>
source§const ENCODERS: &'static [ErasedEncoderEntry] = _
const ENCODERS: &'static [ErasedEncoderEntry] = _
The list of encoder vtables.
source§impl<T> StructEncodeMetadata<Resource> for MpscReceiver<T>where
T: MeshField,
impl<T> StructEncodeMetadata<Resource> for MpscReceiver<T>where
T: MeshField,
source§const ENCODERS: &'static [ErasedEncoderEntry] = _
const ENCODERS: &'static [ErasedEncoderEntry] = _
The list of encoder vtables.
source§impl<T> StructEncodeMetadata<Resource> for MpscSender<T>where
T: MeshField,
impl<T> StructEncodeMetadata<Resource> for MpscSender<T>where
T: MeshField,
source§const ENCODERS: &'static [ErasedEncoderEntry] = _
const ENCODERS: &'static [ErasedEncoderEntry] = _
The list of encoder vtables.
source§impl<T> StructEncodeMetadata<Resource> for OneshotReceiver<T>where
T: MeshField,
impl<T> StructEncodeMetadata<Resource> for OneshotReceiver<T>where
T: MeshField,
source§const ENCODERS: &'static [ErasedEncoderEntry] = _
const ENCODERS: &'static [ErasedEncoderEntry] = _
The list of encoder vtables.
source§impl<T> StructEncodeMetadata<Resource> for OneshotSender<T>where
T: MeshField,
impl<T> StructEncodeMetadata<Resource> for OneshotSender<T>where
T: MeshField,
source§const ENCODERS: &'static [ErasedEncoderEntry] = _
const ENCODERS: &'static [ErasedEncoderEntry] = _
The list of encoder vtables.
source§impl<T> StructEncodeMetadata<Resource> for Receiver<T>where
T: MeshField,
impl<T> StructEncodeMetadata<Resource> for Receiver<T>where
T: MeshField,
source§const ENCODERS: &'static [ErasedEncoderEntry] = _
const ENCODERS: &'static [ErasedEncoderEntry] = _
The list of encoder vtables.
source§impl<I, R> StructEncodeMetadata<Resource> for Rpc<I, R>
impl<I, R> StructEncodeMetadata<Resource> for Rpc<I, R>
source§const ENCODERS: &'static [ErasedEncoderEntry] = _
const ENCODERS: &'static [ErasedEncoderEntry] = _
The list of encoder vtables.
source§impl<T> StructEncodeMetadata<Resource> for Sender<T>where
T: MeshField,
impl<T> StructEncodeMetadata<Resource> for Sender<T>where
T: MeshField,
source§const ENCODERS: &'static [ErasedEncoderEntry] = _
const ENCODERS: &'static [ErasedEncoderEntry] = _
The list of encoder vtables.
source§impl StructEncodeMetadata<Resource> for WritePipe
impl StructEncodeMetadata<Resource> for WritePipe
source§const ENCODERS: &'static [ErasedEncoderEntry] = _
const ENCODERS: &'static [ErasedEncoderEntry] = _
The list of encoder vtables.
Auto Trait Implementations§
impl Freeze for Resource
impl !RefUnwindSafe for Resource
impl Send for Resource
impl Sync for Resource
impl Unpin for Resource
impl !UnwindSafe for Resource
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more