pub trait Subscriber<T>: 'static {
// Required method
fn write(&mut self, item: &T);
}Expand description
What a component does with an item it was handed by an analysis broadcast
— the port of uvm_subscriber’s write.
It takes &mut self and returns nothing: delivery is synchronous and in
zero time, so there is no async, no back-pressure, and nothing to await.
Implement it on the state a subscriber keeps, not on the component (a
sibling cannot be reached from a run phase); see
RustdvShared. The UVM makes the subscriber a
component; here it is the plain struct the component hosts.
Required Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".