[−][src]Struct linux_futex::op::Op
The operation wake_op
applies to the second futex.
An Op
must be combined with a Cmp
by using the plus operator. For
example: Op::assign(1) + Cmp::eq(0)
The argument to any operation must be below 1 << 12
(= 4096).
Implementations
impl Op
[src]
pub fn assign(arg: u32) -> Self
[src]
Assign the argument to the futex value: value = arg
pub fn add(arg: u32) -> Self
[src]
Add the argument to the futex value: value += arg
pub fn or(arg: u32) -> Self
[src]
Bitwise-or the futex value with the argument: value |= arg
pub fn and_not(arg: u32) -> Self
[src]
Bitwise-and the futex value with the bitwise complement of the argument: value &= !arg
pub fn xor(arg: u32) -> Self
[src]
Xor the futex value with the argument: value ^= arg
pub fn assign_bit(bit: u32) -> Self
[src]
Assign 1 << bit
to the futex value: value = 1 << bit
pub fn add_bit(bit: u32) -> Self
[src]
Add 1 << bit
to the futex value: value += 1 << bit
pub fn set_bit(bit: u32) -> Self
[src]
Set the bit
th bit of the futex value: value |= 1 << bit
pub fn clear_bit(bit: u32) -> Self
[src]
Clear the bit
th bit of the futex value: value &= !(1 << bit)
pub fn toggle_bit(bit: u32) -> Self
[src]
Toggle the bit
th bit of the futex value: value ^= 1 << bit
Trait Implementations
impl Add<Cmp> for Op
[src]
type Output = OpAndCmp
The resulting type after applying the +
operator.
fn add(self, cmp: Cmp) -> OpAndCmp
[src]
impl Clone for Op
[src]
impl Copy for Op
[src]
impl Debug for Op
[src]
impl Eq for Op
[src]
impl PartialEq<Op> for Op
[src]
impl StructuralEq for Op
[src]
impl StructuralPartialEq for Op
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
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>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,