[][src]Struct kernel::common::registers::ReadOnly

pub struct ReadOnly<T, R = ()> where
    R: RegisterLongName,
    T: IntLike
{ value: T, associated_register: PhantomData<R>, }

Read-only registers.


value: Tassociated_register: PhantomData<R>


impl<T, R> ReadOnly<T, R> where
    R: RegisterLongName,
    T: IntLike

pub fn get(&self) -> T[src]

pub fn read(&self, field: Field<T, R>) -> T[src]

pub fn read_as_enum<E>(&self, field: Field<T, R>) -> Option<E> where
    E: TryFromValue<T, EnumType = E>, 

pub fn extract(&self) -> LocalRegisterCopy<T, R>[src]

pub fn is_set(&self, field: Field<T, R>) -> bool[src]

pub fn matches_any(&self, field: FieldValue<T, R>) -> bool[src]

pub fn matches_all(&self, field: FieldValue<T, R>) -> bool[src]

Auto Trait Implementations

impl<T, R> Unpin for ReadOnly<T, R> where
    R: Unpin,
    T: Unpin

impl<T, R> Send for ReadOnly<T, R> where
    R: Send,
    T: Send

impl<T, R> Sync for ReadOnly<T, R> where
    R: Sync,
    T: Sync

Blanket Implementations

impl<T> From<T> for T[src]

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

type Error = Infallible

The type returned in the event of a conversion error.

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

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.

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

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

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