[−][src]Struct uom::si::fmt::Arguments
A struct to specify a display style and unit.
Usage
Indirect style
let l = Length::new::<meter>(1.0); let a = Length::format_args(centimeter, Description); assert_eq!("100 centimeters", format!("{}", a.with(l)));
Direct style
let l = Length::new::<meter>(1.0); let a = l.into_format_args(centimeter, Description); assert_eq!("100 centimeters", format!("{}", a));
Methods
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Acceleration<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Acceleration<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: AmountOfSubstance<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: AmountOfSubstance<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Angle<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Angle<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: AngularAcceleration<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: AngularAcceleration<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: AngularVelocity<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: AngularVelocity<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Area<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Area<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: AvailableEnergy<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: AvailableEnergy<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Capacitance<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Capacitance<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: ElectricCharge<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: ElectricCharge<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: ElectricCurrent<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: ElectricCurrent<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: ElectricPotential<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: ElectricPotential<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: ElectricalConductance<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: ElectricalConductance<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: ElectricalResistance<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: ElectricalResistance<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Energy<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Energy<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Force<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Force<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Frequency<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Frequency<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Inductance<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Inductance<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Jerk<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Jerk<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Length<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Length<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Luminance<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Luminance<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: LuminousIntensity<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: LuminousIntensity<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: MagneticFlux<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: MagneticFlux<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: MagneticFluxDensity<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: MagneticFluxDensity<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Mass<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Mass<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: MassDensity<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: MassDensity<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: MassRate<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: MassRate<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Momentum<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Momentum<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Power<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Power<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Pressure<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Pressure<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Ratio<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Ratio<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: TemperatureInterval<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: TemperatureInterval<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: ThermodynamicTemperature<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: ThermodynamicTemperature<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Time<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Time<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Torque<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Torque<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Velocity<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Velocity<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: Volume<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: Volume<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
impl<N> Arguments<Dimension, N> where
N: Unit + Unit,
[src]
N: Unit + Unit,
pub fn with<U: ?Sized, V>(
self,
quantity: VolumeRate<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
[src]
self,
quantity: VolumeRate<U, V>
) -> QuantityArguments<Dimension, U, V, N> where
U: Units<V>,
V: Num + Conversion<V>,
Specifies a quantity to display.
Trait Implementations
impl<D: ?Sized, N> Copy for Arguments<D, N> where
D: Dimension,
N: Unit,
[src]
D: Dimension,
N: Unit,
impl<D: ?Sized, N> Clone for Arguments<D, N> where
D: Dimension,
N: Unit,
[src]
D: Dimension,
N: Unit,
Auto Trait Implementations
impl<D: ?Sized, N> Send for Arguments<D, N> where
N: Send,
N: Send,
impl<D: ?Sized, N> Sync for Arguments<D, N> where
N: Sync,
N: Sync,
Blanket Implementations
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> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for 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>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
ⓘImportant traits for &'_ mut Rfn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Same<T> for T
[src]
type Output = T
Should always be Self