[][src]Trait rust_3d::IsND

pub trait IsND {
    fn n_dimensions() -> usize
    where
        Self: Sized
;
fn position_nd(&self, dimension: usize) -> Result<f64>; }

IsND is a trait used for types which are positioned within the n-dimensional space

Required methods

fn n_dimensions() -> usize where
    Self: Sized

Should return the number of dimensions. E.g. 2 for points in 2D space, 3 for points in 3D space etc.

fn position_nd(&self, dimension: usize) -> Result<f64>

Should return the value of a given dimensions. E.g. for 2D position with x = 4.3, y = 1.8 the result for dimension = 1 should be 1.8

Loading content...

Implementations on Foreign Types

impl<P> IsND for Box<P> where
    P: IsND
[src]

Loading content...

Implementors

impl IsND for BoundingBox2D[src]

impl IsND for BoundingBox3D[src]

impl IsND for Box2D[src]

impl IsND for Box3D[src]

impl IsND for Circle[src]

impl IsND for FilterBox2D[src]

impl IsND for FilterBox3D[src]

impl IsND for FilterCircle[src]

impl IsND for FilterSphere[src]

impl IsND for Norm2D[src]

impl IsND for Norm3D[src]

impl IsND for Point2D[src]

impl IsND for Point3D[src]

impl IsND for Sphere[src]

Loading content...