Skip to main content
← PSoXide SDK guides and examples · SDK 80d1c329e977 · All Cargo features enabled; check feature gates before use.

Staged

Struct Staged 

Source
pub struct Staged<'a, const N: usize>(/* private fields */);
Expand description

The card as the planning closure sees it. Reads come from the writes queued so far, then from the cached directory; writes are queued, not sent. It is the Block under the Card that CardJob::plan passes.

It holds the directory only: a read of any other frame that no queued write covers fails with Error::OutOfRange. format, write, delete, list, free_blocks and is_formatted read nothing else. A write past the queue’s capacity fails with Error::NoSpace.

Trait Implementations§

Source§

impl<const N: usize> Block for Staged<'_, N>

Source§

fn read_frame(&mut self, frame: u16, out: &mut [u8; 128]) -> Result<()>

Read frame frame (0..FRAME_COUNT) into out.
Source§

fn write_frame(&mut self, frame: u16, data: &[u8; 128]) -> Result<()>

Write data to frame frame (0..FRAME_COUNT).
Source§

fn write_frame_unsettled(&mut self, frame: u16, data: &[u8; 128]) -> Result<()>

write_frame without waiting out the card’s commit time afterwards. Read more

Auto Trait Implementations§

§

impl<'a, const N: usize> Freeze for Staged<'a, N>

§

impl<'a, const N: usize> RefUnwindSafe for Staged<'a, N>

§

impl<'a, const N: usize> Send for Staged<'a, N>

§

impl<'a, const N: usize> Sync for Staged<'a, N>

§

impl<'a, const N: usize> Unpin for Staged<'a, N>

§

impl<'a, const N: usize> UnsafeUnpin for Staged<'a, N>

§

impl<'a, const N: usize> !UnwindSafe for Staged<'a, N>

Blanket Implementations§

§

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

§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

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

§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
§

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

§

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

Mutably borrows from an owned value. Read more
§

impl<T> From<T> for T

§

fn from(t: T) -> T

Returns the argument unchanged.

§

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

§

fn into(self) -> U

Calls U::from(self).

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

§

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

§

type Error = Infallible

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

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

Performs the conversion.
§

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

§

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

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

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

Performs the conversion.