pub struct Voltage(/* private fields */);
Expand description
A voltage.
This type represents a voltage value in microvolts.
Implementations§
Source§impl Voltage
impl Voltage
Sourcepub fn from_microvolts(uv: i32) -> Self
pub fn from_microvolts(uv: i32) -> Self
Creates a new Voltage
from a value in microvolts.
Sourcepub fn as_microvolts(self) -> i32
pub fn as_microvolts(self) -> i32
Returns the value of the voltage in microvolts as an i32
.
Trait Implementations§
impl Copy for Voltage
impl Eq for Voltage
impl StructuralPartialEq for Voltage
Auto Trait Implementations§
impl Freeze for Voltage
impl RefUnwindSafe for Voltage
impl Send for Voltage
impl Sync for Voltage
impl Unpin for Voltage
impl UnwindSafe for Voltage
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> PinInit<T> for T
impl<T> PinInit<T> for T
Source§unsafe fn __pinned_init(self, slot: *mut T) -> Result<(), Infallible>
unsafe fn __pinned_init(self, slot: *mut T) -> Result<(), Infallible>
Initializes
slot
. Read more