pub trait LogScalable: Clone {
    // Required methods
    fn as_f64(&self) -> f64;
    fn from_f64(f: f64) -> Self;
}
Expand description

The trait for the type that is able to be presented in the log scale. This trait is primarily used by LogRangeExt.

Required Methods§

source

fn as_f64(&self) -> f64

Make the conversion from the type to the floating point number

source

fn from_f64(f: f64) -> Self

Convert a floating point number to the scale

Implementations on Foreign Types§

source§

impl LogScalable for u16

source§

fn as_f64(&self) -> f64

source§

fn from_f64(f: f64) -> u16

source§

impl LogScalable for f32

source§

fn as_f64(&self) -> f64

source§

fn from_f64(f: f64) -> f32

source§

impl LogScalable for i16

source§

fn as_f64(&self) -> f64

source§

fn from_f64(f: f64) -> i16

source§

impl LogScalable for u32

source§

fn as_f64(&self) -> f64

source§

fn from_f64(f: f64) -> u32

source§

impl LogScalable for i64

source§

fn as_f64(&self) -> f64

source§

fn from_f64(f: f64) -> i64

source§

impl LogScalable for u8

source§

fn as_f64(&self) -> f64

source§

fn from_f64(f: f64) -> u8

source§

impl LogScalable for f64

source§

fn as_f64(&self) -> f64

source§

fn from_f64(f: f64) -> f64

source§

impl LogScalable for u64

source§

fn as_f64(&self) -> f64

source§

fn from_f64(f: f64) -> u64

source§

impl LogScalable for i32

source§

fn as_f64(&self) -> f64

source§

fn from_f64(f: f64) -> i32

source§

impl LogScalable for i8

source§

fn as_f64(&self) -> f64

source§

fn from_f64(f: f64) -> i8

Implementors§