pub enum BitFieldSubCommand<E = &'static str, O = &'static str>where
    E: SingleArg,
    O: SingleArg,{
    Get(BitFieldGetSubCommand<E, O>),
    Set(E, O, u64),
    IncrBy(E, O, i64),
    Overflow(BitFieldOverflow),
}
Expand description

Sub-command for the bitfield command

Variants§

§

Get(BitFieldGetSubCommand<E, O>)

§

Set(E, O, u64)

§

IncrBy(E, O, i64)

§

Overflow(BitFieldOverflow)

Implementations§

source§

impl<E, O> BitFieldSubCommand<E, O>where E: SingleArg, O: SingleArg,

source

pub fn get(encoding: E, offset: O) -> Self

Returns the specified bit field.

source

pub fn set(encoding: E, offset: O, value: u64) -> Self

Set the specified bit field and returns its old value.

source

pub fn incr_by(encoding: E, offset: O, increment: i64) -> Self

Increments or decrements (if a negative increment is given) the specified bit field and returns the new value.

source

pub fn overflow(overflow: BitFieldOverflow) -> Self

Trait Implementations§

source§

impl<E, O> ToArgs for BitFieldSubCommand<E, O>where E: SingleArg, O: SingleArg,

source§

fn write_args(&self, args: &mut CommandArgs)

Write this Rust type as one ore multiple args into CommandArgs. Read more
source§

fn num_args(&self) -> usize

Number arguments generated by this Rust type

Auto Trait Implementations§

§

impl<E, O> RefUnwindSafe for BitFieldSubCommand<E, O>where E: RefUnwindSafe, O: RefUnwindSafe,

§

impl<E, O> Send for BitFieldSubCommand<E, O>where E: Send, O: Send,

§

impl<E, O> Sync for BitFieldSubCommand<E, O>where E: Sync, O: Sync,

§

impl<E, O> Unpin for BitFieldSubCommand<E, O>where E: Unpin, O: Unpin,

§

impl<E, O> UnwindSafe for BitFieldSubCommand<E, O>where E: UnwindSafe, O: UnwindSafe,

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere 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> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for Twhere 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 Twhere U: Into<T>,

§

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 Twhere U: TryFrom<T>,

§

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.
§

impl<V, T> VZip<V> for Twhere V: MultiLane<T>,

§

fn vzip(self) -> V

source§

impl<T> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

impl<T> MultipleArgsCollection<T> for Twhere T: ToArgs,