Var

Struct Var 

Source
pub struct Var<T>(/* private fields */);
Expand description

An immutable labeled expression. Passed by reference

Trait Implementations§

Source§

impl<T: Expr> Expr for &Var<T>

Source§

type Target = <T as Expr>::Target

Target primitive type.
Source§

fn get_type() -> ElementType

Get the element type of this expression
Source§

fn var(expr: String) -> Var<Self::Target>

Create a variable of target type
Source§

impl<T: Expr> Expr for Var<T>

Source§

type Target = <T as Expr>::Target

Target primitive type.
Source§

fn get_type() -> ElementType

Get the element type of this expression
Source§

fn var(expr: String) -> Var<Self::Target>

Create a variable of target type
Source§

impl From<&Var<Conic>> for Conic

Source§

fn from(value: &Var<Conic>) -> Self

Converts to this type from the input type.
Source§

impl From<&Var<Line>> for Line

Source§

fn from(value: &Var<Line>) -> Self

Converts to this type from the input type.
Source§

impl<T> From<&Var<List<T>>> for List<T>

Source§

fn from(value: &Var<List<T>>) -> Self

Converts to this type from the input type.
Source§

impl From<&Var<Numeric>> for Numeric

Source§

fn from(value: &Var<Numeric>) -> Self

Converts to this type from the input type.
Source§

impl From<&Var<Point>> for Point

Source§

fn from(value: &Var<Point>) -> Self

Converts to this type from the input type.
Source§

impl From<&Var<Ray>> for Ray

Source§

fn from(value: &Var<Ray>) -> Self

Converts to this type from the input type.
Source§

impl From<&Var<Segment>> for Segment

Source§

fn from(value: &Var<Segment>) -> Self

Converts to this type from the input type.
Source§

impl<T> From<&Var<T>> for Expression

Source§

fn from(value: &Var<T>) -> Self

Converts to this type from the input type.
Source§

impl From<Var<Conic>> for Conic

Source§

fn from(value: Var<Conic>) -> Self

Converts to this type from the input type.
Source§

impl From<Var<Line>> for Line

Source§

fn from(value: Var<Line>) -> Self

Converts to this type from the input type.
Source§

impl From<Var<Point>> for Point

Source§

fn from(value: Var<Point>) -> Self

Converts to this type from the input type.
Source§

impl From<Var<Ray>> for Ray

Source§

fn from(value: Var<Ray>) -> Self

Converts to this type from the input type.
Source§

impl From<Var<Segment>> for Segment

Source§

fn from(value: Var<Segment>) -> Self

Converts to this type from the input type.
Source§

impl<T> From<Var<T>> for Expression

Source§

fn from(value: Var<T>) -> Self

Converts to this type from the input type.
Source§

impl<T: Object> Object for &Var<T>

Source§

impl<T: Object> Object for Var<T>

Auto Trait Implementations§

§

impl<T> Freeze for Var<T>

§

impl<T> RefUnwindSafe for Var<T>
where T: RefUnwindSafe,

§

impl<T> !Send for Var<T>

§

impl<T> !Sync for Var<T>

§

impl<T> Unpin for Var<T>
where T: Unpin,

§

impl<T> UnwindSafe for Var<T>
where T: UnwindSafe,

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> ConicAccess for T
where Conic: From<T>,

Source§

fn center(self) -> Point

Get the conic’s center
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> LineAccess for T
where Line: From<T>,

Source§

fn direction(self) -> Numeric

Direction vector of this line
Source§

impl<T> PointAccess for T
where Point: From<T>,

Source§

fn x(self) -> Numeric

Get the x coordinate of this point
Source§

fn y(self) -> Numeric

Get the y coordinate of this point
Source§

fn complex(self) -> Numeric

Convert to a complex number
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
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.