pub struct Handle<T: Timestamp> {
frontier: Rc<RefCell<MutableAntichain<T>>>,
handle_frontier: Antichain<T>,
notify: Rc<Notify>,
}
Fields§
§frontier: Rc<RefCell<MutableAntichain<T>>>
The overall shared frontier managed by all the handles
handle_frontier: Antichain<T>
The private frontier containing the changes produced by this handle only
notify: Rc<Notify>
Implementations§
Source§impl<T: Timestamp> Handle<T>
impl<T: Timestamp> Handle<T>
Sourcepub async fn progressed(&self)
pub async fn progressed(&self)
Wait for the frontier monitored by this probe to progress
Sourcepub fn less_than(&self, time: &T) -> bool
pub fn less_than(&self, time: &T) -> bool
Returns true iff the frontier is strictly less than time
.
Sourcepub fn less_equal(&self, time: &T) -> bool
pub fn less_equal(&self, time: &T) -> bool
Returns true iff the frontier is less than or equal to time
.
Sourcepub fn with_frontier<R, F: FnMut(AntichainRef<'_, T>) -> R>(
&self,
function: F,
) -> R
pub fn with_frontier<R, F: FnMut(AntichainRef<'_, T>) -> R>( &self, function: F, ) -> R
Invokes a method on the frontier, returning its result.
This method allows inspection of the frontier, which cannot be returned by reference as
it is on the other side of a RefCell
.
§Examples
use mz_timely_util::probe::Handle;
let handle = Handle::<usize>::default();
let frontier = handle.with_frontier(|frontier| frontier.to_vec());
fn update_frontier(&mut self, new_frontier: &[T])
Trait Implementations§
Auto Trait Implementations§
impl<T> Freeze for Handle<T>where
T: Freeze,
impl<T> !RefUnwindSafe for Handle<T>
impl<T> !Send for Handle<T>
impl<T> !Sync for Handle<T>
impl<T> Unpin for Handle<T>where
T: Unpin,
impl<T> !UnwindSafe for Handle<T>
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
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<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request
Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> ProgressEventTimestamp for T
impl<T> ProgressEventTimestamp for T
Source§impl<'a, S, T> Semigroup<&'a S> for Twhere
T: Semigroup<S>,
impl<'a, S, T> Semigroup<&'a S> for Twhere
T: Semigroup<S>,
Source§fn plus_equals(&mut self, rhs: &&'a S)
fn plus_equals(&mut self, rhs: &&'a S)
The method of
std::ops::AddAssign
, for types that do not implement AddAssign
.