Trait bevy_reflect::Struct

source ·
pub trait Struct: Reflect {
    // Required methods
    fn field(&self, name: &str) -> Option<&dyn Reflect>;
    fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>;
    fn field_at(&self, index: usize) -> Option<&dyn Reflect>;
    fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>;
    fn name_at(&self, index: usize) -> Option<&str>;
    fn field_len(&self) -> usize;
    fn iter_fields(&self) -> FieldIter<'_> ;
    fn clone_dynamic(&self) -> DynamicStruct;
}
Expand description

A trait used to power struct-like operations via reflection.

This trait uses the Reflect trait to allow implementors to have their fields be dynamically addressed by both name and index.

When using #[derive(Reflect)] on a standard struct, this trait will be automatically implemented. This goes for unit structs as well.

Example

use bevy_reflect::{Reflect, Struct};

#[derive(Reflect)]
struct Foo {
    bar: u32,
}

let foo = Foo { bar: 123 };

assert_eq!(foo.field_len(), 1);
assert_eq!(foo.name_at(0), Some("bar"));

let field: &dyn Reflect = foo.field("bar").unwrap();
assert_eq!(field.downcast_ref::<u32>(), Some(&123));

Required Methods§

source

fn field(&self, name: &str) -> Option<&dyn Reflect>

Returns a reference to the value of the field named name as a &dyn Reflect.

source

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

Returns a mutable reference to the value of the field named name as a &mut dyn Reflect.

source

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

Returns a reference to the value of the field with index index as a &dyn Reflect.

source

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

Returns a mutable reference to the value of the field with index index as a &mut dyn Reflect.

source

fn name_at(&self, index: usize) -> Option<&str>

Returns the name of the field with index index.

source

fn field_len(&self) -> usize

Returns the number of fields in the struct.

source

fn iter_fields(&self) -> FieldIter<'_>

Returns an iterator over the values of the reflectable fields for this struct.

source

fn clone_dynamic(&self) -> DynamicStruct

Clones the struct into a DynamicStruct.

Trait Implementations§

source§

impl GetField for dyn Struct

source§

fn get_field<T: Reflect>(&self, name: &str) -> Option<&T>

Returns a reference to the value of the field named name, downcast to T.
source§

fn get_field_mut<T: Reflect>(&mut self, name: &str) -> Option<&mut T>

Returns a mutable reference to the value of the field named name, downcast to T.

Implementations on Foreign Types§

source§

impl Struct for Capsule2d
where Self: Any + Send + Sync, f32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Circle
where Self: Any + Send + Sync, f32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Ellipse
where Self: Any + Send + Sync, Vec2: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Line2d

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Plane2d

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Rectangle
where Self: Any + Send + Sync, Vec2: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for RegularPolygon

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Segment2d

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Triangle2d
where Self: Any + Send + Sync, [Vec2; 3]: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Capsule3d
where Self: Any + Send + Sync, f32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Cone
where Self: Any + Send + Sync, f32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for ConicalFrustum
where Self: Any + Send + Sync, f32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Cuboid
where Self: Any + Send + Sync, Vec3: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Cylinder
where Self: Any + Send + Sync, f32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Line3d

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Plane3d

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Segment3d

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Sphere
where Self: Any + Send + Sync, f32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Torus
where Self: Any + Send + Sync, f32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for IRect
where Self: Any + Send + Sync, IVec2: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Rect
where Self: Any + Send + Sync, Vec2: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for URect
where Self: Any + Send + Sync, UVec2: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for BVec2
where Self: Any + Send + Sync, bool: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for BVec3
where Self: Any + Send + Sync, bool: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for BVec4
where Self: Any + Send + Sync, bool: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Affine2

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Affine3A

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Mat3
where Self: Any + Send + Sync, Vec3: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Mat2
where Self: Any + Send + Sync, Vec2: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Mat3A
where Self: Any + Send + Sync, Vec3A: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Mat4
where Self: Any + Send + Sync, Vec4: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Quat
where Self: Any + Send + Sync, f32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Vec3A
where Self: Any + Send + Sync, f32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Vec4
where Self: Any + Send + Sync, f32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Vec2
where Self: Any + Send + Sync, f32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for Vec3
where Self: Any + Send + Sync, f32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for DAffine2

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for DAffine3

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for DMat2
where Self: Any + Send + Sync, DVec2: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for DMat3
where Self: Any + Send + Sync, DVec3: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for DMat4
where Self: Any + Send + Sync, DVec4: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for DQuat
where Self: Any + Send + Sync, f64: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for DVec2
where Self: Any + Send + Sync, f64: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for DVec3
where Self: Any + Send + Sync, f64: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for DVec4
where Self: Any + Send + Sync, f64: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for IVec2
where Self: Any + Send + Sync, i32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for IVec3
where Self: Any + Send + Sync, i32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for IVec4
where Self: Any + Send + Sync, i32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for I64Vec2
where Self: Any + Send + Sync, i64: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for I64Vec3
where Self: Any + Send + Sync, i64: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for I64Vec4
where Self: Any + Send + Sync, i64: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for UVec2
where Self: Any + Send + Sync, u32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for UVec3
where Self: Any + Send + Sync, u32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for UVec4
where Self: Any + Send + Sync, u32: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for U64Vec2
where Self: Any + Send + Sync, u64: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for U64Vec3
where Self: Any + Send + Sync, u64: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl Struct for U64Vec4
where Self: Any + Send + Sync, u64: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl<const N: usize> Struct for Polygon<N>
where Self: Any + Send + Sync, [Vec2; N]: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl<const N: usize> Struct for Polyline2d<N>
where Self: Any + Send + Sync, [Vec2; N]: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

source§

impl<const N: usize> Struct for Polyline3d<N>
where Self: Any + Send + Sync, [Vec3; N]: FromReflect + TypePath,

source§

fn field(&self, name: &str) -> Option<&dyn Reflect>

source§

fn field_mut(&mut self, name: &str) -> Option<&mut dyn Reflect>

source§

fn field_at(&self, index: usize) -> Option<&dyn Reflect>

source§

fn field_at_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>

source§

fn name_at(&self, index: usize) -> Option<&str>

source§

fn field_len(&self) -> usize

source§

fn iter_fields(&self) -> FieldIter<'_>

source§

fn clone_dynamic(&self) -> DynamicStruct

Implementors§