Skip to main content

Shape

Trait Shape 

Source
pub trait Shape {
    // Required methods
    fn id(&self) -> ShapeId;
    fn key(&self, name: &str) -> Option<Key>;
}
Expand description

The names a view answers.

Required Methods§

Source

fn id(&self) -> ShapeId

The shape’s identity. Two views with the same id resolve every name to the same key.

Source

fn key(&self, name: &str) -> Option<Key>

The key for a field or method name.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl Shape for Fields<'_>