ExpressionNumber
trait · ferroui-controls · v0.5.0
trait ExpressionNumber: Copy
A number type the expressions are evaluated with: its arithmetic, None where a result is not
a value of the type.
Members
is_zero
fn is_zero(self: &Self) -> bool
Whether the number is zero (a divisor that is zero is a division by zero).
add
fn add(self: Self, other: Self) -> Option<Self>
The sum.
sub
fn sub(self: Self, other: Self) -> Option<Self>
The difference.
mul
fn mul(self: Self, other: Self) -> Option<Self>
The product.
div
fn div(self: Self, other: Self) -> Option<Self>
The quotient; other is not zero.
pow
fn pow(self: Self, exponent: Self) -> Option<Self>
self raised to the power exponent.
Trait implementations
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.