Skip to main content

ToApi

Trait ToApi 

Source
pub trait ToApi {
    type Equivalent;

    // Required method
    fn to_api(self) -> Self::Equivalent;
}
Expand description

Converts a unit from kcmc to its equivalent for kcl_api.

Required Associated Types§

Required Methods§

Source

fn to_api(self) -> Self::Equivalent

Converts this unit of measurement from kcmc to its equivalent for kcl_api.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl ToApi for UnitAngle

Source§

impl ToApi for UnitArea

Source§

impl ToApi for UnitDensity

Source§

impl ToApi for UnitLength

Source§

impl ToApi for UnitMass

Source§

impl ToApi for UnitVolume

Implementors§