Skip to main content

CommandOperation

Struct CommandOperation 

Source
pub struct CommandOperation<'b, B, AddressType, InFieldset, OutFieldset, Repeat>
where B: Block, B::Interface: CommandInterfaceBase<AddressType = AddressType>, AddressType: Address,
{ /* private fields */ }
Expand description

Intermediate type for doing command operations

Implementations§

Source§

impl<'d, B, AddressType, InFieldset, OutFieldset, Repeat> CommandOperation<'d, B, AddressType, InFieldset, OutFieldset, Repeat>
where B: Block, B::Interface: CommandInterfaceBase<AddressType = AddressType>, AddressType: Address,

Source

pub fn dispatch( self, ) -> Result<(), <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: CommandInterface, InFieldset: NotFieldset, OutFieldset: NotFieldset, Repeat: NotRepeating,

Dispatch the command to the device

Source

pub fn dispatch_at( self, index: Repeat::Index, ) -> Result<(), <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: CommandInterface, InFieldset: NotFieldset, OutFieldset: NotFieldset, Repeat: Repeating,

Dispatch the command to the device

Source

pub fn dispatch_async( self, ) -> impl Future<Output = Result<(), <B::Interface as CommandInterfaceBase>::Error>>
where B::Interface: AsyncCommandInterface, InFieldset: NotFieldset, OutFieldset: NotFieldset, Repeat: NotRepeating,

Dispatch the command to the device

Source

pub fn dispatch_at_async( self, index: Repeat::Index, ) -> impl Future<Output = Result<(), <B::Interface as CommandInterfaceBase>::Error>>
where B::Interface: AsyncCommandInterface, InFieldset: NotFieldset, OutFieldset: NotFieldset, Repeat: Repeating,

Dispatch the command to the device

Source

pub fn dispatch_in( self, f: impl FnOnce(&mut InFieldset), ) -> Result<(), <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: CommandInterface, InFieldset: Fieldset, OutFieldset: NotFieldset, Repeat: NotRepeating,

Dispatch the command to the device with an input

Source

pub fn dispatch_in_at( self, index: Repeat::Index, f: impl FnOnce(&mut InFieldset), ) -> Result<(), <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: CommandInterface, InFieldset: Fieldset, OutFieldset: NotFieldset, Repeat: Repeating,

Dispatch the command to the device with an input

Source

pub async fn dispatch_in_async( self, f: impl FnOnce(&mut InFieldset), ) -> Result<(), <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: AsyncCommandInterface, InFieldset: Fieldset, OutFieldset: NotFieldset, Repeat: NotRepeating,

Dispatch the command to the device with an input

Source

pub async fn dispatch_in_at_async( self, index: Repeat::Index, f: impl FnOnce(&mut InFieldset), ) -> Result<(), <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: AsyncCommandInterface, InFieldset: Fieldset, OutFieldset: NotFieldset, Repeat: Repeating,

Dispatch the command to the device with an input

Source

pub fn dispatch_out( self, ) -> Result<OutFieldset, <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: CommandInterface, InFieldset: NotFieldset, OutFieldset: Fieldset, Repeat: NotRepeating,

Dispatch the command to the device with an output

Source

pub fn dispatch_out_at( self, index: Repeat::Index, ) -> Result<OutFieldset, <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: CommandInterface, InFieldset: NotFieldset, OutFieldset: Fieldset, Repeat: Repeating,

Dispatch the command to the device with an output

Source

pub async fn dispatch_out_async( self, ) -> Result<OutFieldset, <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: AsyncCommandInterface, InFieldset: NotFieldset, OutFieldset: Fieldset, Repeat: NotRepeating,

Dispatch the command to the device with an output

Source

pub async fn dispatch_out_at_async( self, index: Repeat::Index, ) -> Result<OutFieldset, <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: AsyncCommandInterface, InFieldset: NotFieldset, OutFieldset: Fieldset, Repeat: Repeating,

Dispatch the command to the device with an output

Source

pub fn dispatch_inout( self, f: impl FnOnce(&mut InFieldset), ) -> Result<OutFieldset, <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: CommandInterface, InFieldset: Fieldset, OutFieldset: Fieldset, Repeat: NotRepeating,

Dispatch the command to the device with an input and output

Source

pub fn dispatch_inout_at( self, index: Repeat::Index, f: impl FnOnce(&mut InFieldset), ) -> Result<OutFieldset, <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: CommandInterface, InFieldset: Fieldset, OutFieldset: Fieldset, Repeat: Repeating,

Dispatch the command to the device with an input and output

Source

pub async fn dispatch_inout_async( self, f: impl FnOnce(&mut InFieldset), ) -> Result<OutFieldset, <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: AsyncCommandInterface, InFieldset: Fieldset, OutFieldset: Fieldset, Repeat: NotRepeating,

Dispatch the command to the device with an input and output

Source

pub async fn dispatch_inout_at_async( self, index: Repeat::Index, f: impl FnOnce(&mut InFieldset), ) -> Result<OutFieldset, <B::Interface as CommandInterfaceBase>::Error>
where B::Interface: AsyncCommandInterface, InFieldset: Fieldset, OutFieldset: Fieldset, Repeat: Repeating,

Dispatch the command to the device with an input and output

Auto Trait Implementations§

§

impl<'b, B, AddressType, InFieldset, OutFieldset, Repeat> !UnwindSafe for CommandOperation<'b, B, AddressType, InFieldset, OutFieldset, Repeat>

§

impl<'b, B, AddressType, InFieldset, OutFieldset, Repeat> Freeze for CommandOperation<'b, B, AddressType, InFieldset, OutFieldset, Repeat>
where AddressType: Freeze,

§

impl<'b, B, AddressType, InFieldset, OutFieldset, Repeat> RefUnwindSafe for CommandOperation<'b, B, AddressType, InFieldset, OutFieldset, Repeat>
where AddressType: RefUnwindSafe, B: RefUnwindSafe, InFieldset: RefUnwindSafe, OutFieldset: RefUnwindSafe, Repeat: RefUnwindSafe,

§

impl<'b, B, AddressType, InFieldset, OutFieldset, Repeat> Send for CommandOperation<'b, B, AddressType, InFieldset, OutFieldset, Repeat>
where AddressType: Send, B: Send, InFieldset: Send, OutFieldset: Send, Repeat: Send,

§

impl<'b, B, AddressType, InFieldset, OutFieldset, Repeat> Sync for CommandOperation<'b, B, AddressType, InFieldset, OutFieldset, Repeat>
where AddressType: Sync, B: Sync, InFieldset: Sync, OutFieldset: Sync, Repeat: Sync,

§

impl<'b, B, AddressType, InFieldset, OutFieldset, Repeat> Unpin for CommandOperation<'b, B, AddressType, InFieldset, OutFieldset, Repeat>
where AddressType: Unpin, InFieldset: Unpin, OutFieldset: Unpin, Repeat: Unpin,

§

impl<'b, B, AddressType, InFieldset, OutFieldset, Repeat> UnsafeUnpin for CommandOperation<'b, B, AddressType, InFieldset, OutFieldset, Repeat>
where AddressType: UnsafeUnpin,

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 = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

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.