pub trait Shape3D {
// Required method
fn shape(&self) -> (usize, usize, usize);
}Expand description
Trait for 3D structures that have dimensions.
This trait provides a uniform interface for querying the dimensions of 3D volumes and meshes.
§Example
use shortestpath::mesh_3d::{Shape3D, Full3D};
let mesh = Full3D::new(10, 8, 5);
let (width, height, depth) = mesh.shape();
assert_eq!(width, 10);
assert_eq!(height, 8);
assert_eq!(depth, 5);