Myth16

Struct Myth16 

Source
pub struct Myth16(/* private fields */);
Expand description

§16bit measurement type

A type to calculate lossless dimensions with a fixed 4 digit precision.

All sizes are defined in the tenth fraction of μ:

  • 10 = 1 μ
  • 10_000 = 1 mm
  • 30_000 = 3 mm

The standard Display::fmt-method represents the value in mm. The alternate Display shows the i16 value.

As 10_000 = 1 mm

§Warning

Casting an i64 into a Myth16 can cause an IntegerOverflow-error similar to casting a big i64-value into an i16. It’s up to the programmer to omit these situation.

If your sizes can exceed 3 mm, than this type is not for you. Again:

Don’t try to store more then +/- 3 millimeter in a Myth16.

§Example:

    let myth = Myth16::from(1.5);

    assert_eq!(format!("{myth}"), "1.5");
    assert_eq!(format!("{myth:.2}"), "1.50");
    assert_eq!(format!("{myth:.4}"),"1.5000");
    assert_eq!(format!("{myth:#}"), "15000");

Implementations§

Source§

impl Myth16

Source

pub const fn as_i16(&self) -> i16

Source§

impl Myth16

Source

pub const ONE: Myth16

The neutral element in relation to multiplication and division.

Source

pub const ZERO: Myth16

The neutral element in relation to addition and subtraction.

Source

pub const MIN: Myth16

Source

pub const MAX: Myth16

Source

pub const MM: Myth16

👎Deprecated since 1.0.3: please use ONE instead.
Source

pub const fn as_i64(&self) -> i64

Returns the value as a i64 in “1/10 μ”.

Source

pub fn as_mm(&self) -> f64

👎Deprecated since 1.0.3: please use as_f64 instead.

Returns the value as a f64 in “mm”.

Source

pub fn as_f64(&self) -> f64

Returns the value as a f64 in “mm”.

Source

pub fn as_unit(&self, unit: Unit) -> f64

Returns the value in the given Unit.

Source

pub fn round(&self, unit: Unit) -> Self

Rounds to the given Unit.

Source

pub fn floor(&self, unit: Unit) -> Self

Finds the nearest value less than or equal to an integer multiple of the given Unit.

Source

pub const fn abs(&self) -> Self

Computes the absolute value of self.

Source

pub const fn abs_diff(self, other: Myth16) -> Self

Computes the absolute difference between self and other.

Source

pub const fn signum(self) -> Self

Returns a Myth16 representing the sign of self.

  • 0 if the number is zero
  • 1 if the number is positive
  • -1 if the number is negative
Source

pub const fn is_negative(&self) -> bool

Returns true if self is negative and false if zero or positive.

Source

pub const fn is_positive(&self) -> bool

Returns true if self is positive and false if zero or negative.

Source

pub const fn is_zero(&self) -> bool

Returns true if self is zero.

Source

pub const fn to_be_bytes(&self) -> [u8; 2]

Returns the memory representation of this Myth16 as a byte array in big-endian (network) byte order.

Source

pub const fn to_le_bytes(&self) -> [u8; 2]

Returns the memory representation of this Myth16 as a byte array in little-endian byte order.

Source

pub const fn to_ne_bytes(&self) -> [u8; 2]

Returns the memory representation of this Myth16 as a byte array in native byte order.

Source

pub const fn from_be_bytes(bytes: [u8; 2]) -> Self

Creates a Myth16 value from its representation as a byte array in big-endian.

Source

pub const fn from_le_bytes(bytes: [u8; 2]) -> Self

Creates a Myth16 value from its representation as a byte array in little endian.

Source

pub const fn from_ne_bytes(bytes: [u8; 2]) -> Self

Creates a Myth16 value from its representation as a byte array in native byte order.

Trait Implementations§

Source§

impl<'a> Add<&'a Myth16> for Myth16

Source§

type Output = Myth16

The resulting type after applying the + operator.
Source§

fn add(self, other: &'a Myth16) -> Self::Output

Performs the + operation. Read more
Source§

impl<'a> Add<&'a Myth16> for Myth32

Source§

type Output = Myth32

The resulting type after applying the + operator.
Source§

fn add(self, other: &'a Myth16) -> Self::Output

Performs the + operation. Read more
Source§

impl<'a> Add<&'a Myth16> for Myth64

Source§

type Output = Myth64

The resulting type after applying the + operator.
Source§

fn add(self, other: &'a Myth16) -> Self::Output

Performs the + operation. Read more
Source§

impl Add<Myth16> for Myth32

Source§

type Output = Myth32

The resulting type after applying the + operator.
Source§

fn add(self, other: Myth16) -> Self::Output

Performs the + operation. Read more
Source§

impl Add<Myth16> for Myth64

Source§

type Output = Myth64

The resulting type after applying the + operator.
Source§

fn add(self, other: Myth16) -> Self::Output

Performs the + operation. Read more
Source§

impl Add<Myth16> for T64

Source§

type Output = T64

The resulting type after applying the + operator.
Source§

fn add(self, other: Myth16) -> T64

Performs the + operation. Read more
Source§

impl Add<i16> for Myth16

Source§

type Output = Myth16

The resulting type after applying the + operator.
Source§

fn add(self, other: i16) -> Self::Output

Performs the + operation. Read more
Source§

impl Add<i32> for Myth16

Source§

type Output = Myth16

The resulting type after applying the + operator.
Source§

fn add(self, other: i32) -> Self::Output

Performs the + operation. Read more
Source§

impl Add<i64> for Myth16

Source§

type Output = Myth16

The resulting type after applying the + operator.
Source§

fn add(self, other: i64) -> Self::Output

Performs the + operation. Read more
Source§

impl Add<i8> for Myth16

Source§

type Output = Myth16

The resulting type after applying the + operator.
Source§

fn add(self, other: i8) -> Self::Output

Performs the + operation. Read more
Source§

impl Add<isize> for Myth16

Source§

type Output = Myth16

The resulting type after applying the + operator.
Source§

fn add(self, other: isize) -> Self::Output

Performs the + operation. Read more
Source§

impl Add<u16> for Myth16

Source§

type Output = Myth16

The resulting type after applying the + operator.
Source§

fn add(self, other: u16) -> Self::Output

Performs the + operation. Read more
Source§

impl Add<u32> for Myth16

Source§

type Output = Myth16

The resulting type after applying the + operator.
Source§

fn add(self, other: u32) -> Self::Output

Performs the + operation. Read more
Source§

impl Add<u64> for Myth16

Source§

type Output = Myth16

The resulting type after applying the + operator.
Source§

fn add(self, other: u64) -> Self::Output

Performs the + operation. Read more
Source§

impl Add<u8> for Myth16

Source§

type Output = Myth16

The resulting type after applying the + operator.
Source§

fn add(self, other: u8) -> Self::Output

Performs the + operation. Read more
Source§

impl Add<usize> for Myth16

Source§

type Output = Myth16

The resulting type after applying the + operator.
Source§

fn add(self, other: usize) -> Self::Output

Performs the + operation. Read more
Source§

impl Add for Myth16

Source§

type Output = Myth16

The resulting type after applying the + operator.
Source§

fn add(self, other: Myth16) -> Self::Output

Performs the + operation. Read more
Source§

impl AddAssign<Myth16> for T64

Source§

fn add_assign(&mut self, other: Myth16)

Performs the += operation. Read more
Source§

impl AddAssign for Myth16

Source§

fn add_assign(&mut self, other: Self)

Performs the += operation. Read more
Source§

impl Clone for Myth16

Source§

fn clone(&self) -> Myth16

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Myth16

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Myth16

Source§

fn default() -> Myth16

Returns the “default value” for a type. Read more
Source§

impl Display for Myth16

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'a> Div<i16> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: i16) -> Self::Output

Performs the / operation. Read more
Source§

impl Div<i16> for Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: i16) -> Self::Output

Performs the / operation. Read more
Source§

impl<'a> Div<i32> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: i32) -> Self::Output

Performs the / operation. Read more
Source§

impl Div<i32> for Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: i32) -> Self::Output

Performs the / operation. Read more
Source§

impl<'a> Div<i64> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: i64) -> Self::Output

Performs the / operation. Read more
Source§

impl Div<i64> for Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: i64) -> Self::Output

Performs the / operation. Read more
Source§

impl<'a> Div<i8> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: i8) -> Self::Output

Performs the / operation. Read more
Source§

impl Div<i8> for Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: i8) -> Self::Output

Performs the / operation. Read more
Source§

impl<'a> Div<isize> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: isize) -> Self::Output

Performs the / operation. Read more
Source§

impl Div<isize> for Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: isize) -> Self::Output

Performs the / operation. Read more
Source§

impl<'a> Div<u16> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: u16) -> Self::Output

Performs the / operation. Read more
Source§

impl Div<u16> for Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: u16) -> Self::Output

Performs the / operation. Read more
Source§

impl<'a> Div<u32> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: u32) -> Self::Output

Performs the / operation. Read more
Source§

impl Div<u32> for Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: u32) -> Self::Output

Performs the / operation. Read more
Source§

impl<'a> Div<u64> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: u64) -> Self::Output

Performs the / operation. Read more
Source§

impl Div<u64> for Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: u64) -> Self::Output

Performs the / operation. Read more
Source§

impl<'a> Div<u8> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: u8) -> Self::Output

Performs the / operation. Read more
Source§

impl Div<u8> for Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: u8) -> Self::Output

Performs the / operation. Read more
Source§

impl<'a> Div<usize> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: usize) -> Self::Output

Performs the / operation. Read more
Source§

impl Div<usize> for Myth16

Source§

type Output = Myth16

The resulting type after applying the / operator.
Source§

fn div(self, other: usize) -> Self::Output

Performs the / operation. Read more
Source§

impl<'a> From<&'a Myth16> for i16

Source§

fn from(a: &Myth16) -> Self

Converts to this type from the input type.
Source§

impl<'a> From<&'a Myth16> for i8

Source§

fn from(a: &Myth16) -> Self

Converts to this type from the input type.
Source§

impl<'a> From<&'a Myth16> for u8

Source§

fn from(a: &Myth16) -> Self

Converts to this type from the input type.
Source§

impl From<Myth16> for Myth32

Source§

fn from(m: Myth16) -> Self

Converts to this type from the input type.
Source§

impl From<Myth16> for Myth64

Source§

fn from(m: Myth16) -> Self

Converts to this type from the input type.
Source§

impl From<Myth16> for f64

Source§

fn from(f: Myth16) -> Self

Converts to this type from the input type.
Source§

impl From<Myth16> for i16

Source§

fn from(a: Myth16) -> Self

Converts to this type from the input type.
Source§

impl From<Myth16> for i8

Source§

fn from(a: Myth16) -> Self

Converts to this type from the input type.
Source§

impl From<Myth16> for u8

Source§

fn from(a: Myth16) -> Self

Converts to this type from the input type.
Source§

impl From<Unit> for Myth16

Source§

fn from(unit: Unit) -> Self

Converts to this type from the input type.
Source§

impl From<f64> for Myth16

Source§

fn from(f: f64) -> Self

Converts to this type from the input type.
Source§

impl From<i16> for Myth16

Source§

fn from(a: i16) -> Self

Converts to this type from the input type.
Source§

impl From<i32> for Myth16

A potentially dangerous function. Use it for creating Myth16 in tests or where you can control the danger.

Source§

fn from(value: i32) -> Self

Converts to this type from the input type.
Source§

impl From<i8> for Myth16

Source§

fn from(a: i8) -> Self

Converts to this type from the input type.
Source§

impl From<u8> for Myth16

Source§

fn from(a: u8) -> Self

Converts to this type from the input type.
Source§

impl FromStr for Myth16

Source§

type Err = ToleranceError

The associated error which can be returned from parsing.
Source§

fn from_str(value: &str) -> Result<Self, Self::Err>

Parses a string s to return a value of this type. Read more
Source§

impl Hash for Myth16

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl Mul<Myth16> for i16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: Myth16) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<Myth16> for i32

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: Myth16) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<Myth16> for i64

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: Myth16) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<Myth16> for i8

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: Myth16) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<Myth16> for isize

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: Myth16) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<Myth16> for u16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: Myth16) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<Myth16> for u32

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: Myth16) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<Myth16> for u64

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: Myth16) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<Myth16> for u8

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: Myth16) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<Myth16> for usize

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: Myth16) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a> Mul<i16> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: i16) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<i16> for Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: i16) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a> Mul<i32> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: i32) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<i32> for Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: i32) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a> Mul<i64> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: i64) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<i64> for Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: i64) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a> Mul<i8> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: i8) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<i8> for Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: i8) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a> Mul<isize> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: isize) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<isize> for Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: isize) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a> Mul<u16> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: u16) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<u16> for Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: u16) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a> Mul<u32> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: u32) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<u32> for Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: u32) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a> Mul<u64> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: u64) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<u64> for Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: u64) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a> Mul<u8> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: u8) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<u8> for Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: u8) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a> Mul<usize> for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: usize) -> Self::Output

Performs the * operation. Read more
Source§

impl Mul<usize> for Myth16

Source§

type Output = Myth16

The resulting type after applying the * operator.
Source§

fn mul(self, other: usize) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a> Neg for &'a Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn neg(self) -> Self::Output

Performs the unary - operation. Read more
Source§

impl Neg for Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn neg(self) -> Self::Output

Performs the unary - operation. Read more
Source§

impl Ord for Myth16

Source§

fn cmp(&self, other: &Myth16) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · Source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · Source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · Source§

fn clamp(self, min: Self, max: Self) -> Self
where Self: Sized,

Restrict a value to a certain interval. Read more
Source§

impl PartialEq for Myth16

Source§

fn eq(&self, other: &Myth16) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl PartialOrd for Myth16

Source§

fn partial_cmp(&self, other: &Myth16) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · Source§

fn lt(&self, other: &Rhs) -> bool

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · Source§

fn le(&self, other: &Rhs) -> bool

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · Source§

fn gt(&self, other: &Rhs) -> bool

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · Source§

fn ge(&self, other: &Rhs) -> bool

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl<'a> Sub<&'a Myth16> for Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn sub(self, other: &'a Myth16) -> Self::Output

Performs the - operation. Read more
Source§

impl<'a> Sub<&'a Myth16> for Myth32

Source§

type Output = Myth32

The resulting type after applying the - operator.
Source§

fn sub(self, other: &'a Myth16) -> Self::Output

Performs the - operation. Read more
Source§

impl<'a> Sub<&'a Myth16> for Myth64

Source§

type Output = Myth64

The resulting type after applying the - operator.
Source§

fn sub(self, other: &'a Myth16) -> Self::Output

Performs the - operation. Read more
Source§

impl Sub<Myth16> for Myth32

Source§

type Output = Myth32

The resulting type after applying the - operator.
Source§

fn sub(self, other: Myth16) -> Self::Output

Performs the - operation. Read more
Source§

impl Sub<Myth16> for Myth64

Source§

type Output = Myth64

The resulting type after applying the - operator.
Source§

fn sub(self, other: Myth16) -> Self::Output

Performs the - operation. Read more
Source§

impl Sub<Myth16> for T64

Source§

type Output = T64

The resulting type after applying the - operator.
Source§

fn sub(self, other: Myth16) -> T64

Performs the - operation. Read more
Source§

impl Sub<i16> for Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn sub(self, other: i16) -> Self::Output

Performs the - operation. Read more
Source§

impl Sub<i32> for Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn sub(self, other: i32) -> Self::Output

Performs the - operation. Read more
Source§

impl Sub<i64> for Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn sub(self, other: i64) -> Self::Output

Performs the - operation. Read more
Source§

impl Sub<i8> for Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn sub(self, other: i8) -> Self::Output

Performs the - operation. Read more
Source§

impl Sub<isize> for Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn sub(self, other: isize) -> Self::Output

Performs the - operation. Read more
Source§

impl Sub<u16> for Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn sub(self, other: u16) -> Self::Output

Performs the - operation. Read more
Source§

impl Sub<u32> for Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn sub(self, other: u32) -> Self::Output

Performs the - operation. Read more
Source§

impl Sub<u64> for Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn sub(self, other: u64) -> Self::Output

Performs the - operation. Read more
Source§

impl Sub<u8> for Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn sub(self, other: u8) -> Self::Output

Performs the - operation. Read more
Source§

impl Sub<usize> for Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn sub(self, other: usize) -> Self::Output

Performs the - operation. Read more
Source§

impl Sub for Myth16

Source§

type Output = Myth16

The resulting type after applying the - operator.
Source§

fn sub(self, other: Myth16) -> Self::Output

Performs the - operation. Read more
Source§

impl SubAssign<Myth16> for T64

Source§

fn sub_assign(&mut self, other: Myth16)

Performs the -= operation. Read more
Source§

impl SubAssign for Myth16

Source§

fn sub_assign(&mut self, other: Self)

Performs the -= operation. Read more
Source§

impl<'a> Sum<&'a Myth16> for Myth16

Source§

fn sum<I: Iterator<Item = &'a Self>>(iter: I) -> Self

Takes an iterator and generates Self from the elements by “summing up” the items.
Source§

impl Sum for Myth16

Source§

fn sum<I: Iterator<Item = Self>>(iter: I) -> Self

Takes an iterator and generates Self from the elements by “summing up” the items.
Source§

impl TryFrom<&str> for Myth16

Source§

type Error = ToleranceError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &str) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl TryFrom<Myth32> for Myth16

Source§

type Error = ToleranceError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Myth32) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl TryFrom<Myth64> for Myth16

Source§

type Error = ToleranceError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Myth64) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl TryFrom<String> for Myth16

Source§

type Error = ToleranceError

The type returned in the event of a conversion error.
Source§

fn try_from(value: String) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl TryFrom<i64> for Myth16

Source§

type Error = ToleranceError

The type returned in the event of a conversion error.
Source§

fn try_from(value: i64) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl TryFrom<isize> for Myth16

Source§

type Error = ToleranceError

The type returned in the event of a conversion error.
Source§

fn try_from(value: isize) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl TryFrom<u16> for Myth16

Source§

type Error = ToleranceError

The type returned in the event of a conversion error.
Source§

fn try_from(value: u16) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl TryFrom<u32> for Myth16

Source§

type Error = ToleranceError

The type returned in the event of a conversion error.
Source§

fn try_from(value: u32) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl TryFrom<u64> for Myth16

Source§

type Error = ToleranceError

The type returned in the event of a conversion error.
Source§

fn try_from(value: u64) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl TryFrom<usize> for Myth16

Source§

type Error = ToleranceError

The type returned in the event of a conversion error.
Source§

fn try_from(value: usize) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl Copy for Myth16

Source§

impl Eq for Myth16

Source§

impl StructuralPartialEq for Myth16

Auto Trait Implementations§

§

impl Freeze for Myth16

§

impl RefUnwindSafe for Myth16

§

impl Send for Myth16

§

impl Sync for Myth16

§

impl Unpin for Myth16

§

impl UnwindSafe for Myth16

Blanket Implementations§

Source§

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

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

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

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

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

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

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

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

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

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

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

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.