angle

Trait Angle

Source
pub trait Angle<N> {
Show 15 methods // Required methods fn pi() -> Self where N: NumCast; fn two_pi() -> Self where N: NumCast; fn half_pi() -> Self where N: NumCast; fn to_rad(self) -> Rad<N> where N: NumCast; fn to_deg(self) -> Deg<N> where N: NumCast; fn wrap(self) -> Self where N: NumCast + Clone; fn max(self, other: Self) -> Self where N: PartialOrd + NumCast + Clone; fn min(self, other: Self) -> Self where N: PartialOrd + NumCast + Clone; fn value(self) -> N; fn as_value(&self) -> &N; fn sin(self) -> N where N: Float + NumCast; fn cos(self) -> N where N: Float + NumCast; fn tan(self) -> N where N: Float + NumCast; fn sin_cos(self) -> (N, N) where N: Float + NumCast; fn abs(self) -> Self where N: Signed;
}

Required Methods§

Source

fn pi() -> Self
where N: NumCast,

Source

fn two_pi() -> Self
where N: NumCast,

Source

fn half_pi() -> Self
where N: NumCast,

Source

fn to_rad(self) -> Rad<N>
where N: NumCast,

Source

fn to_deg(self) -> Deg<N>
where N: NumCast,

Source

fn wrap(self) -> Self
where N: NumCast + Clone,

Source

fn max(self, other: Self) -> Self
where N: PartialOrd + NumCast + Clone,

Source

fn min(self, other: Self) -> Self
where N: PartialOrd + NumCast + Clone,

Source

fn value(self) -> N

Source

fn as_value(&self) -> &N

Source

fn sin(self) -> N
where N: Float + NumCast,

Source

fn cos(self) -> N
where N: Float + NumCast,

Source

fn tan(self) -> N
where N: Float + NumCast,

Source

fn sin_cos(self) -> (N, N)
where N: Float + NumCast,

Source

fn abs(self) -> Self
where N: Signed,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<N: Num> Angle<N> for Deg<N>

Source§

impl<N: Num> Angle<N> for Rad<N>