Skip to main content

UslpTransferFrameBuilder

Struct UslpTransferFrameBuilder 

Source
pub struct UslpTransferFrameBuilder<'f1, S: State = Empty> { /* private fields */ }
Expand description

Use builder syntax to set the inputs and finish with build().

Implementations§

Source§

impl<'f1, S: State> UslpTransferFrameBuilder<'f1, S>

Source

pub fn build(self) -> Result<&'f1 mut UslpTransferFrame, BuildError>
where S: IsComplete,

Finishes building and performs the requested action.

Source

pub fn buffer( self, value: &'f1 mut [u8], ) -> UslpTransferFrameBuilder<'f1, SetBuffer<S>>
where S::Buffer: IsUnset,

Required.

Source

pub fn scid(self, value: Scid) -> UslpTransferFrameBuilder<'f1, SetScid<S>>
where S::Scid: IsUnset,

Required.

Source

pub fn vcid(self, value: Vcid) -> UslpTransferFrameBuilder<'f1, SetVcid<S>>
where S::Vcid: IsUnset,

Required.

Source

pub fn source_or_dest( self, value: bool, ) -> UslpTransferFrameBuilder<'f1, SetSourceOrDest<S>>
where S::SourceOrDest: IsUnset,

Optional (Some / Option setters). Default: false.

Source

pub fn maybe_source_or_dest( self, value: Option<bool>, ) -> UslpTransferFrameBuilder<'f1, SetSourceOrDest<S>>
where S::SourceOrDest: IsUnset,

Optional (Some / Option setters). Default: false.

Source

pub fn map_id(self, value: u8) -> UslpTransferFrameBuilder<'f1, SetMapId<S>>
where S::MapId: IsUnset,

Optional (Some / Option setters). Default: 0.

Source

pub fn maybe_map_id( self, value: Option<u8>, ) -> UslpTransferFrameBuilder<'f1, SetMapId<S>>
where S::MapId: IsUnset,

Optional (Some / Option setters). Default: 0.

Source

pub fn bypass(self, value: bool) -> UslpTransferFrameBuilder<'f1, SetBypass<S>>
where S::Bypass: IsUnset,

Optional (Some / Option setters). Default: false.

Source

pub fn maybe_bypass( self, value: Option<bool>, ) -> UslpTransferFrameBuilder<'f1, SetBypass<S>>
where S::Bypass: IsUnset,

Optional (Some / Option setters). Default: false.

Source

pub fn protocol_control_command( self, value: bool, ) -> UslpTransferFrameBuilder<'f1, SetProtocolControlCommand<S>>
where S::ProtocolControlCommand: IsUnset,

Optional (Some / Option setters). Default: false.

Source

pub fn maybe_protocol_control_command( self, value: Option<bool>, ) -> UslpTransferFrameBuilder<'f1, SetProtocolControlCommand<S>>
where S::ProtocolControlCommand: IsUnset,

Optional (Some / Option setters). Default: false.

Source

pub fn ocf_flag( self, value: bool, ) -> UslpTransferFrameBuilder<'f1, SetOcfFlag<S>>
where S::OcfFlag: IsUnset,

Optional (Some / Option setters). Default: false.

Source

pub fn maybe_ocf_flag( self, value: Option<bool>, ) -> UslpTransferFrameBuilder<'f1, SetOcfFlag<S>>
where S::OcfFlag: IsUnset,

Optional (Some / Option setters). Default: false.

Source

pub fn vcf_count_length( self, value: u8, ) -> UslpTransferFrameBuilder<'f1, SetVcfCountLength<S>>
where S::VcfCountLength: IsUnset,

Optional (Some / Option setters). Default: 0.

Source

pub fn maybe_vcf_count_length( self, value: Option<u8>, ) -> UslpTransferFrameBuilder<'f1, SetVcfCountLength<S>>
where S::VcfCountLength: IsUnset,

Optional (Some / Option setters). Default: 0.

Source

pub fn vcf_count( self, value: u64, ) -> UslpTransferFrameBuilder<'f1, SetVcfCount<S>>
where S::VcfCount: IsUnset,

Optional (Some / Option setters). Default: 0.

Source

pub fn maybe_vcf_count( self, value: Option<u64>, ) -> UslpTransferFrameBuilder<'f1, SetVcfCount<S>>
where S::VcfCount: IsUnset,

Optional (Some / Option setters). Default: 0.

Auto Trait Implementations§

§

impl<'f1, S> Freeze for UslpTransferFrameBuilder<'f1, S>

§

impl<'f1, S> RefUnwindSafe for UslpTransferFrameBuilder<'f1, S>

§

impl<'f1, S> Send for UslpTransferFrameBuilder<'f1, S>

§

impl<'f1, S> Sync for UslpTransferFrameBuilder<'f1, S>

§

impl<'f1, S> Unpin for UslpTransferFrameBuilder<'f1, S>

§

impl<'f1, S> UnsafeUnpin for UslpTransferFrameBuilder<'f1, S>

§

impl<'f1, S = Empty> !UnwindSafe for UslpTransferFrameBuilder<'f1, S>

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> Same for T

Source§

type Output = T

Should always be Self
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.