pub struct Dr7Value { /* private fields */ }
Expand description

A valid value of the Dr7 debug register.

In addition to the Dr7Flags this value has a condition field and a size field for each debug address register.

Implementations§

source§

impl Dr7Value

source

pub const fn from_bits(bits: u64) -> Option<Self>

Convert from underlying bit representation, unless that representation contains bits that do not correspond to a field.

source

pub const fn from_bits_truncate(bits: u64) -> Self

Convert from underlying bit representation, dropping any bits that do not correspond to fields.

source

pub const unsafe fn from_bits_unchecked(bits: u64) -> Self

Convert from underlying bit representation, preserving all bits (even those not corresponding to a defined field).

§Safety

The bit representation must be a valid Dr7Value.

source

pub const fn bits(&self) -> u64

Returns the raw value of the fields currently stored.

source

pub const fn flags(self) -> Dr7Flags

Returns the Dr7Flags in this value.

source

pub fn insert_flags(&mut self, flags: Dr7Flags)

Inserts the specified Dr7Flags in-place.

source

pub fn remove_flags(&mut self, flags: Dr7Flags)

Removes the specified Dr7Flags in-place.

source

pub fn toggle_flags(&mut self, flags: Dr7Flags)

Toggles the specified Dr7Flags in-place.

source

pub fn set_flags(&mut self, flags: Dr7Flags, value: bool)

Inserts or removes the specified Dr7Flags depending on the passed value.

source

pub fn condition(&self, n: DebugAddressRegisterNumber) -> BreakpointCondition

Returns the condition field of a debug address register.

source

pub fn set_condition( &mut self, n: DebugAddressRegisterNumber, condition: BreakpointCondition )

Sets the condition field of a debug address register.

source

pub fn size(&self, n: DebugAddressRegisterNumber) -> BreakpointSize

Returns the size field of a debug address register.

source

pub fn set_size(&mut self, n: DebugAddressRegisterNumber, size: BreakpointSize)

Sets the size field of a debug address register.

Trait Implementations§

source§

impl Clone for Dr7Value

source§

fn clone(&self) -> Dr7Value

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Dr7Value

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<Dr7Flags> for Dr7Value

source§

fn from(dr7_flags: Dr7Flags) -> Self

Converts to this type from the input type.
source§

impl PartialEq for Dr7Value

source§

fn eq(&self, other: &Dr7Value) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Copy for Dr7Value

source§

impl Eq for Dr7Value

source§

impl StructuralPartialEq for Dr7Value

Auto Trait Implementations§

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>,

§

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>,

§

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.