Skip to main content

WriterHandle

Struct WriterHandle 

Source
pub struct WriterHandle { /* private fields */ }
Expand description

The SignalWriter port role.

The staged changes and the per channel sequence counters live on the handle, not in the store: staging is one provider’s private state until its commit, and a sequence number is assigned by the sender (ridl §3.1).

Trait Implementations§

Source§

impl Attached for WriterHandle

Source§

fn catalog(&self) -> &CatalogRef

The catalog this port serves.
Source§

impl SignalWriter for WriterHandle

Source§

fn set( &mut self, iface: InterfaceNo, ord: Ordinal, bytes: &[u8], ) -> Result<(), WriteError>

Stages a new value.
Source§

fn invalidate( &mut self, iface: InterfaceNo, ord: Ordinal, ) -> Result<(), WriteError>

Stages the invalid state (ridl §4.5), with Cause::Declared.
Source§

fn touch(&mut self, iface: InterfaceNo, ord: Ordinal) -> Result<(), WriteError>

Stages a re-affirmation of the current value, without a new value.
Source§

fn commit(&mut self)

Publishes everything staged. It cannot fail, so it reports nothing — including that the runtime behind the port is gone. A caller learns that from WriteError::Detached on a later set, invalidate or touch, never from that commit. What becomes of the changes staged before a commit whose runtime has already detached is not fixed here.
Source§

impl Wakeable for WriterHandle

Source§

fn wake_on(&self, _: Interest, waker: &Waker)

Wakes waker when the thing what names may have changed, under the contract above.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.