ObjectWorldRef

Struct ObjectWorldRef 

Source
pub struct ObjectWorldRef<'w, T = Any>
where T: Kind,
{ /* private fields */ }
Expand description

Similar to an ObjectRef, but accessible via World.

Implementations§

Source§

impl<'w, T> ObjectWorldRef<'w, T>
where T: Kind,

Source

pub unsafe fn from_any_unchecked( object: ObjectWorldRef<'w>, ) -> ObjectWorldRef<'w, T>

Creates a new ObjectWorldRef<T> from an ObjectWorldRef<Any>.

This is semantically equivalent to an unsafe downcast.

§Safety

Assumes object is of Kind T.

Source

pub fn from_any(object: ObjectWorldRef<'w>) -> Option<ObjectWorldRef<'w, T>>
where T: Component,

Creates a new ObjectWorldRef<T> from an ObjectWorldRef<Any> if the object contains the given Component T.

This is semantically equivalent to a safe downcast.

Source

pub fn get<U>(&self) -> Option<&U>
where U: Component,

Source

pub fn contains<U>(&self) -> bool
where U: Component,

Source

pub fn instance(&self) -> Instance<T>

Returns the object as an Instance<T>.

Source

pub fn entity(&self) -> Entity

Returns the object as an Entity.

Source

pub fn as_entity(&self) -> EntityRef<'w>

Returns the object as an EntityRef.

Trait Implementations§

Source§

impl<T> Clone for ObjectWorldRef<'_, T>
where T: Kind,

Source§

fn clone(&self) -> ObjectWorldRef<'_, T>

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<T> ContainsInstance<T> for ObjectWorldRef<'_, T>
where T: Kind,

Source§

fn instance(&self) -> Instance<T>

Returns the associated Instance<T>.
Source§

fn entity(&self) -> Entity

Returns the Entity of the associated Instance<T>.
Source§

impl<T> Debug for ObjectWorldRef<'_, T>
where T: Kind,

Source§

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

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

impl<T> Deref for ObjectWorldRef<'_, T>
where T: Component,

Source§

type Target = T

The resulting type after dereferencing.
Source§

fn deref(&self) -> &<ObjectWorldRef<'_, T> as Deref>::Target

Dereferences the value.
Source§

impl<T> Display for ObjectWorldRef<'_, T>
where T: Kind,

Source§

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

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

impl<T> From<ObjectWorldRef<'_, T>> for Entity
where T: Kind,

Source§

fn from(object: ObjectWorldRef<'_, T>) -> Entity

Converts to this type from the input type.
Source§

impl<T> From<ObjectWorldRef<'_, T>> for Instance<T>
where T: Kind,

Source§

fn from(object: ObjectWorldRef<'_, T>) -> Instance<T>

Converts to this type from the input type.
Source§

impl<T> ObjectHierarchy<T> for ObjectWorldRef<'_, T>
where T: Kind,

Source§

fn parent( &self, ) -> Option<<ObjectWorldRef<'_, T> as ObjectRebind<T>>::Rebind<Any>>

Returns the parent of this object, if it exists.
Source§

fn children( &self, ) -> impl Iterator<Item = <ObjectWorldRef<'_, T> as ObjectRebind<T>>::Rebind<Any>>

Iterates over all children of this object.
Source§

fn ancestors( &self, ) -> impl Iterator<Item = <ObjectWorldRef<'_, T> as ObjectRebind<T>>::Rebind<Any>>

Iterates over all ancestors of this object.
Source§

fn descendants_wide( &self, ) -> impl Iterator<Item = <ObjectWorldRef<'_, T> as ObjectRebind<T>>::Rebind<Any>>

Iterates over all descendants of this object in breadth-first order.
Source§

fn descendants_deep( &self, ) -> impl Iterator<Item = <ObjectWorldRef<'_, T> as ObjectRebind<T>>::Rebind<Any>>

Iterates over all descendants of this object in depth-first order.
Source§

fn find_by_path( &self, path: impl AsRef<str>, ) -> Option<<ObjectWorldRef<'_, T> as ObjectRebind<T>>::Rebind<Any>>

Attempts to find an object by its path, relative to this one. Read more
Source§

fn root(&self) -> Self::Rebind<Any>

Returns the root of this object’s hierarchy.
Source§

fn is_root(&self) -> bool

Returns true if this object is the root of its hierarchy.
Returns true if this object has the same root as another.
Source§

fn is_child(&self) -> bool

Returns true if this object is a child of another.
Source§

fn is_child_of(&self, entity: Entity) -> bool

Returns true if this object is a child of the given Entity.
Source§

fn has_children(&self) -> bool

Returns true if this object has any children.
Source§

fn query_children<'a, Q, F>( &'a self, query: &'a Query<'_, '_, Q, F>, ) -> impl Iterator<Item = <<Q as QueryData>::ReadOnly as QueryData>::Item<'a, 'a>> + 'a
where Q: QueryData, F: QueryFilter,

Iterates over all children of this object which match the given Query.
Source§

fn children_of_kind<'w, 's, 'a, U>( &'a self, objects: &'a Objects<'w, 's, U>, ) -> impl Iterator<Item = Object<'w, 's, 'a, U>> + 'a
where U: Kind,

Iterates over all children of this object which match the given Kind.
Source§

fn find_child_of_kind<'w, 's, 'a, U>( &self, objects: &'a Objects<'w, 's, U>, ) -> Option<Object<'w, 's, 'a, U>>
where U: Kind,

Returns the first child of this object which matches the given kind, if it exists.
Source§

fn self_and_ancestors(&self) -> impl Iterator<Item = Self::Rebind<Any>>

Iterates over this object, followed by all of its ancestors.
Source§

fn is_ancestor_of<U>(&self, other: &impl ObjectHierarchy<U>) -> bool
where U: Kind, Self::Rebind<Any>: ObjectHierarchy,

Returns true if this object is an ancestor of another.
Source§

fn query_ancestors<'a, Q, F>( &'a self, query: &'a Query<'_, '_, Q, F>, ) -> impl Iterator<Item = <<Q as QueryData>::ReadOnly as QueryData>::Item<'a, 'a>> + 'a
where Q: QueryData, F: QueryFilter,

Iterates over all ancestors of this object which match the given Query.
Source§

fn query_self_and_ancestors<'a, Q, F>( &'a self, query: &'a Query<'_, '_, Q, F>, ) -> impl Iterator<Item = <<Q as QueryData>::ReadOnly as QueryData>::Item<'a, 'a>> + 'a
where Q: QueryData, F: QueryFilter,

Iterates over this object, followed by all its ancestors which match the given Query.
Source§

fn ancestors_of_kind<'w, 's, 'a, U>( &'a self, objects: &'a Objects<'w, 's, U>, ) -> impl Iterator<Item = Object<'w, 's, 'a, U>>
where U: Kind,

Iterates over all ancestors of this object which match the given Kind.
Source§

fn self_and_ancestors_of_kind<'w, 's, 'a, U>( &'a self, objects: &'a Objects<'w, 's, U>, ) -> impl Iterator<Item = Object<'w, 's, 'a, U>>
where U: Kind,

Iterates over this object, followed by all its ancestors which match the given Kind.
Source§

fn find_ancestor_of_kind<'w, 's, 'a, U>( &self, objects: &'a Objects<'w, 's, U>, ) -> Option<Object<'w, 's, 'a, U>>
where U: Kind,

Returns the first ancestor of this object which matches the given Kind, if it exists.
Source§

fn self_and_descendants_wide(&self) -> impl Iterator<Item = Self::Rebind<Any>>

Iterates over this object and all its descendants in breadth-first order.
Source§

fn self_and_descendants_deep(&self) -> impl Iterator<Item = Self::Rebind<Any>>

Iterates over this object and all its descendants in depth-first order.
Source§

fn is_descendant_of(&self, entity: Entity) -> bool
where Self::Rebind<Any>: ObjectHierarchy,

Returns true if this object is a descendant of the given entity.
Source§

fn descendants_of_kind_wide<'w, 's, 'a, U>( &'a self, objects: &'a Objects<'w, 's, U>, ) -> impl Iterator<Item = Object<'w, 's, 'a, U>>
where U: Kind,

Iterates over all descendants of this object which match the given Kind in breadth-first order.
Source§

fn descendants_of_kind_deep<'w, 's, 'a, U>( &'a self, objects: &'a Objects<'w, 's, U>, ) -> impl Iterator<Item = Object<'w, 's, 'a, U>>
where U: Kind,

Iterates over all descendants of this object which match the given Kind in depth-first order.
Source§

fn self_and_descendants_of_kind_wide<'w, 's, 'a, U>( &'a self, objects: &'a Objects<'w, 's, U>, ) -> impl Iterator<Item = Object<'w, 's, 'a, U>>
where U: Kind,

Iterates over this object, followed by all its descendants which match the given Kind in breadth-first order.
Source§

fn self_and_descendants_of_kind_deep<'w, 's, 'a, U>( &'a self, objects: &'a Objects<'w, 's, U>, ) -> impl Iterator<Item = Object<'w, 's, 'a, U>>
where U: Kind,

Iterates over this object, followed by all its descendants which match the given Kind in depth-first order.
Source§

fn query_descendants_wide<'a, Q, F>( &'a self, query: &'a Query<'_, '_, Q, F>, ) -> impl Iterator<Item = <<Q as QueryData>::ReadOnly as QueryData>::Item<'a, 'a>> + 'a
where Q: QueryData, F: QueryFilter,

Iterates over all descendants of this object which match the given Query in breadth-first order.
Source§

fn query_descendants_deep<'a, Q, F>( &'a self, query: &'a Query<'_, '_, Q, F>, ) -> impl Iterator<Item = <<Q as QueryData>::ReadOnly as QueryData>::Item<'a, 'a>> + 'a
where Q: QueryData, F: QueryFilter,

Iterates over all descendants of this object which match the given Kind in depth-first order.
Source§

fn query_self_and_descendants_wide<'a, Q, F>( &'a self, query: &'a Query<'_, '_, Q, F>, ) -> impl Iterator<Item = <<Q as QueryData>::ReadOnly as QueryData>::Item<'a, 'a>> + 'a
where Q: QueryData, F: QueryFilter,

Iterates over this object, followed by all its descendants which match the given Query in breadth-first order.
Source§

fn query_self_and_descendants_deep<'a, Q>( &'a self, query: &'a Query<'_, '_, Q>, ) -> impl Iterator<Item = <<Q as QueryData>::ReadOnly as QueryData>::Item<'a, 'a>> + 'a
where Q: QueryData,

Iterates over this object, followed by all its descendants which match the given Query in depth-first order.
Source§

fn find_descendant_of_kind_wide<'w, 's, 'a, U>( &self, objects: &'a Objects<'w, 's, U>, ) -> Option<Object<'w, 's, 'a, U>>
where U: Kind,

Returns the first descendant of this object (breadth-first order) which matches the given Kind, if it exists.
Source§

fn find_descendant_of_kind_deep<'w, 's, 'a, U>( &self, objects: &'a Objects<'w, 's, U>, ) -> Option<Object<'w, 's, 'a, U>>
where U: Kind,

Returns the first descendant of this object (depth-first order) which matches the given Kind, if it exists.
Source§

fn path(&self) -> String

Returns the path to this object.
Source§

impl<T> ObjectName for ObjectWorldRef<'_, T>
where T: Kind,

Source§

fn name(&self) -> Option<&str>

Returns the Name of this object. Read more
Source§

impl<'w, T> ObjectRebind<T> for ObjectWorldRef<'w, T>
where T: Kind,

Source§

unsafe fn rebind_as<U>( &self, instance: Instance<U>, ) -> <ObjectWorldRef<'w, T> as ObjectRebind<T>>::Rebind<U>
where U: Kind,

Rebinds this object to an Instance of another Kind. Read more
Source§

unsafe fn rebind(&self, instance: Instance<T>) -> Self::Rebind<T>

Rebinds this object to another Instance of the same Kind. Read more
Source§

unsafe fn rebind_any(&self, entity: Entity) -> Self::Rebind<Any>

Rebinds this object to another Entity. Read more
Source§

fn cast_into<U>(self) -> Self::Rebind<U>
where U: Kind, T: CastInto<U>,

Casts this object into another of a related Kind. Read more
Source§

fn cast_into_any(self) -> Self::Rebind<Any>

Casts this object into an Object<Any>. Read more
Source§

unsafe fn cast_into_unchecked<U>(self) -> Self::Rebind<U>
where U: Kind,

Casts this object into another of a different Kind. Read more
Source§

fn as_any(&self) -> Self::Rebind<Any>

Returns this object as an Object<Any>.
Source§

impl<T> ObjectTags for ObjectWorldRef<'_, T>
where T: Kind,

Source§

fn tags(&self) -> &Tags

Returns the Tags of this Object. Read more
Source§

impl<T> PartialEq<Entity> for ObjectWorldRef<'_, T>
where T: Kind,

Source§

fn eq(&self, other: &Entity) -> 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<T> PartialEq<Instance<T>> for ObjectWorldRef<'_, T>
where T: Kind,

Source§

fn eq(&self, other: &Instance<T>) -> 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<T> PartialEq<ObjectWorldRef<'_, T>> for Entity
where T: Kind,

Source§

fn eq(&self, other: &ObjectWorldRef<'_, T>) -> 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<T> PartialEq<ObjectWorldRef<'_, T>> for Instance<T>
where T: Kind,

Source§

fn eq(&self, other: &ObjectWorldRef<'_, T>) -> 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<T, U> PartialEq<ObjectWorldRef<'_, U>> for ObjectWorldRef<'_, T>
where T: Kind, U: Kind,

Source§

fn eq(&self, other: &ObjectWorldRef<'_, U>) -> 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<T> Copy for ObjectWorldRef<'_, T>
where T: Kind,

Source§

impl<T> Eq for ObjectWorldRef<'_, T>
where T: Kind,

Auto Trait Implementations§

§

impl<'w, T> Freeze for ObjectWorldRef<'w, T>

§

impl<'w, T = Any> !RefUnwindSafe for ObjectWorldRef<'w, T>

§

impl<'w, T> Send for ObjectWorldRef<'w, T>

§

impl<'w, T> Sync for ObjectWorldRef<'w, T>

§

impl<'w, T> Unpin for ObjectWorldRef<'w, T>
where T: Unpin,

§

impl<'w, T = Any> !UnwindSafe for ObjectWorldRef<'w, T>

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, C, D> Curve<T> for D
where C: Curve<T> + ?Sized, D: Deref<Target = C>,

Source§

fn domain(&self) -> Interval

The interval over which this curve is parametrized. Read more
Source§

fn sample_unchecked(&self, t: f32) -> T

Sample a point on this curve at the parameter value t, extracting the associated value. This is the unchecked version of sampling, which should only be used if the sample time t is already known to lie within the curve’s domain. Read more
Source§

fn sample(&self, t: f32) -> Option<T>

Sample a point on this curve at the parameter value t, returning None if the point is outside of the curve’s domain.
Source§

fn sample_clamped(&self, t: f32) -> T

Sample a point on this curve at the parameter value t, clamping t to lie inside the domain of the curve.
Source§

impl<C, T> CurveExt<T> for C
where C: Curve<T>,

Source§

fn sample_iter( &self, iter: impl IntoIterator<Item = f32>, ) -> impl Iterator<Item = Option<T>>

Sample a collection of n >= 0 points on this curve at the parameter values t_n, returning None if the point is outside of the curve’s domain. Read more
Source§

fn sample_iter_unchecked( &self, iter: impl IntoIterator<Item = f32>, ) -> impl Iterator<Item = T>

Sample a collection of n >= 0 points on this curve at the parameter values t_n, extracting the associated values. This is the unchecked version of sampling, which should only be used if the sample times t_n are already known to lie within the curve’s domain. Read more
Source§

fn sample_iter_clamped( &self, iter: impl IntoIterator<Item = f32>, ) -> impl Iterator<Item = T>

Sample a collection of n >= 0 points on this curve at the parameter values t_n, clamping t_n to lie inside the domain of the curve. Read more
Source§

fn map<S, F>(self, f: F) -> MapCurve<T, S, Self, F>
where F: Fn(T) -> S,

Create a new curve by mapping the values of this curve via a function f; i.e., if the sample at time t for this curve is x, the value at time t on the new curve will be f(x).
Source§

fn reparametrize<F>(self, domain: Interval, f: F) -> ReparamCurve<T, Self, F>
where F: Fn(f32) -> f32,

Create a new Curve whose parameter space is related to the parameter space of this curve by f. For each time t, the sample from the new curve at time t is the sample from this curve at time f(t). The given domain will be the domain of the new curve. The function f is expected to take domain into self.domain(). Read more
Source§

fn reparametrize_linear( self, domain: Interval, ) -> Result<LinearReparamCurve<T, Self>, LinearReparamError>

Linearly reparametrize this Curve, producing a new curve whose domain is the given domain instead of the current one. This operation is only valid for curves with bounded domains. Read more
Source§

fn reparametrize_by_curve<C>(self, other: C) -> CurveReparamCurve<T, Self, C>
where C: Curve<f32>,

Reparametrize this Curve by sampling from another curve. Read more
Source§

fn graph(self) -> GraphCurve<T, Self>

Create a new Curve which is the graph of this one; that is, its output echoes the sample time as part of a tuple. Read more
Source§

fn zip<S, C>( self, other: C, ) -> Result<ZipCurve<T, S, Self, C>, InvalidIntervalError>
where C: Curve<S>,

Create a new Curve by zipping this curve together with another. Read more
Source§

fn chain<C>(self, other: C) -> Result<ChainCurve<T, Self, C>, ChainError>
where C: Curve<T>,

Create a new Curve by composing this curve end-to-start with another, producing another curve with outputs of the same type. The domain of the other curve is translated so that its start coincides with where this curve ends. Read more
Source§

fn reverse(self) -> Result<ReverseCurve<T, Self>, ReverseError>

Create a new Curve inverting this curve on the x-axis, producing another curve with outputs of the same type, effectively playing backwards starting at self.domain().end() and transitioning over to self.domain().start(). The domain of the new curve is still the same. Read more
Source§

fn repeat(self, count: usize) -> Result<RepeatCurve<T, Self>, RepeatError>

Create a new Curve repeating this curve N times, producing another curve with outputs of the same type. The domain of the new curve will be bigger by a factor of n + 1. Read more
Source§

fn forever(self) -> Result<ForeverCurve<T, Self>, RepeatError>

Create a new Curve repeating this curve forever, producing another curve with outputs of the same type. The domain of the new curve will be unbounded. Read more
Source§

fn ping_pong(self) -> Result<PingPongCurve<T, Self>, PingPongError>

Create a new Curve chaining the original curve with its inverse, producing another curve with outputs of the same type. The domain of the new curve will be twice as long. The transition point is guaranteed to not make any jumps. Read more
Source§

fn chain_continue<C>( self, other: C, ) -> Result<ContinuationCurve<T, Self, C>, ChainError>
where T: VectorSpace, C: Curve<T>,

Create a new Curve by composing this curve end-to-start with another, producing another curve with outputs of the same type. The domain of the other curve is translated so that its start coincides with where this curve ends. Read more
Source§

fn samples( &self, samples: usize, ) -> Result<impl Iterator<Item = T>, ResamplingError>

Extract an iterator over evenly-spaced samples from this curve. Read more
Source§

fn by_ref(&self) -> &Self

Borrow this curve rather than taking ownership of it. This is essentially an alias for a prefix &; the point is that intermediate operations can be performed while retaining access to the original curve. Read more
Source§

fn flip<U, V>(self) -> impl Curve<(V, U)>
where Self: CurveExt<(U, V)>,

Flip this curve so that its tuple output is arranged the other way.
Source§

impl<C, T> CurveResampleExt<T> for C
where C: Curve<T> + ?Sized,

Source§

fn resample<I>( &self, segments: usize, interpolation: I, ) -> Result<SampleCurve<T, I>, ResamplingError>
where I: Fn(&T, &T, f32) -> T,

Resample this Curve to produce a new one that is defined by interpolation over equally spaced sample values, using the provided interpolation to interpolate between adjacent samples. The curve is interpolated on segments segments between samples. For example, if segments is 1, only the start and end points of the curve are used as samples; if segments is 2, a sample at the midpoint is taken as well, and so on. Read more
Source§

fn resample_auto( &self, segments: usize, ) -> Result<SampleAutoCurve<T>, ResamplingError>

Resample this Curve to produce a new one that is defined by interpolation over equally spaced sample values, using automatic interpolation to interpolate between adjacent samples. The curve is interpolated on segments segments between samples. For example, if segments is 1, only the start and end points of the curve are used as samples; if segments is 2, a sample at the midpoint is taken as well, and so on. Read more
Source§

fn resample_uneven<I>( &self, sample_times: impl IntoIterator<Item = f32>, interpolation: I, ) -> Result<UnevenSampleCurve<T, I>, ResamplingError>
where I: Fn(&T, &T, f32) -> T,

Resample this Curve to produce a new one that is defined by interpolation over samples taken at a given set of times. The given interpolation is used to interpolate adjacent samples, and the sample_times are expected to contain at least two valid times within the curve’s domain interval. Read more
Source§

fn resample_uneven_auto( &self, sample_times: impl IntoIterator<Item = f32>, ) -> Result<UnevenSampleAutoCurve<T>, ResamplingError>

Resample this Curve to produce a new one that is defined by automatic interpolation over samples taken at the given set of times. The given sample_times are expected to contain at least two valid times within the curve’s domain interval. Read more
Source§

impl<T, C> CurveWithDerivative<T> for C
where T: HasTangent, C: SampleDerivative<T>,

Source§

fn with_derivative(self) -> SampleDerivativeWrapper<C>

This curve, but with its first derivative included in sampling. Read more
Source§

impl<T> Downcast for T
where T: Any,

Source§

fn into_any(self: Box<T>) -> Box<dyn Any>

Converts Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.
Source§

fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>

Converts Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further downcast into Rc<ConcreteType> where ConcreteType implements Trait.
Source§

fn as_any(&self) -> &(dyn Any + 'static)

Converts &Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &Any’s vtable from &Trait’s.
Source§

fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)

Converts &mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &mut Any’s vtable from &mut Trait’s.
Source§

impl<T> DowncastSend for T
where T: Any + Send,

Source§

fn into_any_send(self: Box<T>) -> Box<dyn Any + Send>

Converts Box<Trait> (where Trait: DowncastSend) to Box<dyn Any + Send>, which can then be downcast into Box<ConcreteType> where ConcreteType implements Trait.
Source§

impl<T> DynEq for T
where T: Any + Eq,

Source§

fn dyn_eq(&self, other: &(dyn DynEq + 'static)) -> bool

This method tests for self and other values to be equal. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, W> HasTypeWitness<W> for T
where W: MakeTypeWitness<Arg = T>, T: ?Sized,

Source§

const WITNESS: W = W::MAKE

A constant of the type witness
Source§

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

Source§

const TYPE_EQ: TypeEq<T, <T as Identity>::Type> = TypeEq::NEW

Proof that Self is the same type as Self::Type, provides methods for casting between Self and Self::Type.
Source§

type Type = T

The same type as Self, used to emulate type equality bounds (T == U) with associated type equality constraints (T: Identity<Type = U>).
Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
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> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> IntoResult<T> for T

Source§

fn into_result(self) -> Result<T, RunSystemError>

Converts this type into the system output type.
Source§

impl<A> Is for A
where A: Any,

Source§

fn is<T>() -> bool
where T: Any,

Checks if the current type “is” another type, using a TypeId equality comparison. This is most useful in the context of generic logic. Read more
Source§

impl<P, T> Receiver for P
where P: Deref<Target = T> + ?Sized, T: ?Sized,

Source§

type Target = T

🔬This is a nightly-only experimental API. (arbitrary_self_types)
The target type on which the method may be called.
Source§

impl<T, C, D> SampleDerivative<T> for D
where T: HasTangent, C: SampleDerivative<T> + ?Sized, D: Deref<Target = C>,

Source§

fn sample_with_derivative_unchecked(&self, t: f32) -> WithDerivative<T>

Sample this curve at the parameter value t, extracting the associated value in addition to its derivative. This is the unchecked version of sampling, which should only be used if the sample time t is already known to lie within the curve’s domain. Read more
Source§

fn sample_with_derivative(&self, t: f32) -> Option<WithDerivative<T>>

Sample this curve’s value and derivative at the parameter value t, returning None if the point is outside of the curve’s domain.
Source§

fn sample_with_derivative_clamped(&self, t: f32) -> WithDerivative<T>

Sample this curve’s value and derivative at the parameter value t, clamping t to lie inside the domain of the curve.
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.
Source§

impl<T> TypeData for T
where T: 'static + Send + Sync + Clone,

Source§

fn clone_type_data(&self) -> Box<dyn TypeData>

Creates a type-erased clone of this value.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> ConditionalSend for T
where T: Send,

Source§

impl<T> Settings for T
where T: 'static + Send + Sync,

Source§

impl<T> Static for T
where T: 'static + Send + Sync,

Source§

impl<T> WasmNotSend for T
where T: Send,

Source§

impl<T> WasmNotSendSync for T

Source§

impl<T> WasmNotSync for T
where T: Sync,