pub enum AccessType {
Ro,
Wo,
Rw,
Const,
}Expand description
Access type enum
Variants§
Ro
Read-only
Wo
Write-only
Rw
Read-write
Const
Read-only, and also will never be changed, even internally by the device
Implementations§
Source§impl AccessType
impl AccessType
Sourcepub fn is_readable(&self) -> bool
pub fn is_readable(&self) -> bool
Returns true if an object with this access type can be read
Sourcepub fn is_writable(&self) -> bool
pub fn is_writable(&self) -> bool
Returns true if an object with this access type can be written
Trait Implementations§
Source§impl Clone for AccessType
impl Clone for AccessType
Source§fn clone(&self) -> AccessType
fn clone(&self) -> AccessType
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AccessType
impl Debug for AccessType
Source§impl Default for AccessType
impl Default for AccessType
Source§fn default() -> AccessType
fn default() -> AccessType
Returns the “default value” for a type. Read more
Source§impl From<AccessType> for AccessTypeDeser
Available on crate feature std only.
impl From<AccessType> for AccessTypeDeser
Available on crate feature
std only.Source§fn from(access_type: AccessType) -> Self
fn from(access_type: AccessType) -> Self
Converts to this type from the input type.
Source§impl PartialEq for AccessType
impl PartialEq for AccessType
impl Copy for AccessType
impl StructuralPartialEq for AccessType
Auto Trait Implementations§
impl Freeze for AccessType
impl RefUnwindSafe for AccessType
impl Send for AccessType
impl Sync for AccessType
impl Unpin for AccessType
impl UnwindSafe for AccessType
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more