pub struct StepHandlerEntry {
pub name: String,
pub matcher: HookMatcher,
pub handler: Arc<dyn StepHandler>,
pub timeout: Option<Duration>,
}Expand description
A fully assembled step handler: name, matcher, handler, and per-entry timeout.
Fields§
§name: StringDisplay name, used only in tracing / observability to identify this hook. Defaults
to an anonymous label (see Self::new); assemblers can override it with
Self::with_name.
matcher: HookMatcher§handler: Arc<dyn StepHandler>§timeout: Option<Duration>Implementations§
Source§impl StepHandlerEntry
impl StepHandlerEntry
pub fn new(matcher: HookMatcher, handler: Arc<dyn StepHandler>) -> Self
Sourcepub fn with_name(self, name: Option<String>) -> Self
pub fn with_name(self, name: Option<String>) -> Self
Sets the display name. None keeps the anonymous placeholder
(ANONYMOUS_HOOK_NAME).
pub fn with_timeout(self, timeout: Duration) -> Self
Auto Trait Implementations§
impl !RefUnwindSafe for StepHandlerEntry
impl !UnwindSafe for StepHandlerEntry
impl Freeze for StepHandlerEntry
impl Send for StepHandlerEntry
impl Sync for StepHandlerEntry
impl Unpin for StepHandlerEntry
impl UnsafeUnpin for StepHandlerEntry
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more