pub trait Apply<E> {
// Required method
fn apply(&mut self, effect: E);
}Expand description
Framework hook to apply one effect during crate::Step.
Authors can apply PushToStack effects to their program inside authored Steps.
The framework does not impose effect handling. Implementations are
extension plumbing for storage/effects, not required component boilerplate.
Stack output implementations use direct typed insertion. This trait neither
executes instructions nor supplies a Step or observer callbacks. The caller
handles crate::Effects in order, applying each effect after execution.
Applied values are not
rolled back if later work fails. Custom fallible effect handling remains in
Step; stack insertion follows PushStack’s ordinary
allocation behavior.
Required Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".