pub struct Delay<Inner = PipeHandle, Clk = TimeClock> {
pub inner: Inner,
/* private fields */
}Fields§
§inner: InnerImplementations§
Source§impl<Inner, Clk> Delay<Inner, Clk>
impl<Inner, Clk> Delay<Inner, Clk>
Sourcepub fn with_clock(inner: Inner, dist: Dist, clock: Clk) -> Self
pub fn with_clock(inner: Inner, dist: Dist, clock: Clk) -> Self
Materialise with an explicit Clock — the seam a deterministic test
or example injects a fake clock through; production code goes via
Delay::new, which defaults Clk to TimeClock.
pub fn with_when(self, when: When) -> Self
pub fn dist(&self) -> Dist
pub fn when(&self) -> Option<When>
Source§impl Delay<PipeHandle, TimeClock>
impl Delay<PipeHandle, TimeClock>
pub fn to_config(&self) -> DelayConfig
pub fn from_spec(inner: PipeHandle, value: &Value) -> Result<Self, ProximaError>
Trait Implementations§
Source§impl<Clk> Pipe for Delay<ThreadLocalPipeHandle, Clk>where
ThreadLocalPipeHandle: Pipe<In = Request<Bytes>, Out = Response<Bytes>, Err = ProximaError>,
Clk: Clock + Clone + 'static,
impl<Clk> Pipe for Delay<ThreadLocalPipeHandle, Clk>where
ThreadLocalPipeHandle: Pipe<In = Request<Bytes>, Out = Response<Bytes>, Err = ProximaError>,
Clk: Clock + Clone + 'static,
Source§type Err = ProximaError
type Err = ProximaError
Auto Trait Implementations§
impl<Inner, Clk> Freeze for Delay<Inner, Clk>
impl<Inner, Clk> RefUnwindSafe for Delay<Inner, Clk>where
Inner: RefUnwindSafe,
Clk: RefUnwindSafe,
impl<Inner, Clk> Send for Delay<Inner, Clk>
impl<Inner, Clk> Sync for Delay<Inner, Clk>
impl<Inner, Clk> Unpin for Delay<Inner, Clk>
impl<Inner, Clk> UnsafeUnpin for Delay<Inner, Clk>where
Inner: UnsafeUnpin,
Clk: UnsafeUnpin,
impl<Inner, Clk> UnwindSafe for Delay<Inner, Clk>where
Inner: UnwindSafe,
Clk: UnwindSafe,
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
impl<Implementor> Handler for Implementor
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<P> PipeExt for Pwhere
P: Pipe,
impl<P> PipeExt for Pwhere
P: Pipe,
Source§fn and_then<Next>(self, next: Next) -> AndThen<Self, Next>
fn and_then<Next>(self, next: Next) -> AndThen<Self, Next>
self.and_then(next) is AndThen::new(self, next) — reads
left-to-right at the call site.Source§fn fanout(self, other: Self) -> FanOut<Self, AllOrNothing>
fn fanout(self, other: Self) -> FanOut<Self, AllOrNothing>
Broadcast to
self and other, all-or-nothing.