pub trait TopologyId:
Copy
+ Eq
+ Ord
+ Debug
+ Hash { }Expand description
Marker trait for compact topology identity handles.
IDs are handles into topology storage, not the storage itself. They are passed by value so traversal APIs can remain simple and static-dispatch friendly. A logical element, relation, or incidence can have different ID representations at different layers. Implementations should document which identity layer each ID type represents and how it maps to other exposed identity layers.
§Performance
Implementations are expected to be small Copy handles. Copying,
comparing, ordering, hashing, and formatting for debug should be O(1).
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementors§
impl<T> TopologyId for T
Blanket implementation for compact ID handle types.
Any type satisfying the TopologyId bounds is a valid topology ID. This
keeps the crate trait-based without requiring implementations to write empty
marker impls for every local handle type.
§Performance
perf: unspecified; performance is inherited from the concrete ID type.