pub struct Capability<T: Timestamp> { /* private fields */ }
Expand description
The capability to send data with a certain timestamp on a dataflow edge.
Capabilities are used by timely dataflow’s progress tracking machinery to restrict and track when user code retains the ability to send messages on dataflow edges. All capabilities are constructed by the system, and should eventually be dropped by the user. Failure to drop a capability (for whatever reason) will cause timely dataflow’s progress tracking to stall.
Implementations§
Source§impl<T: Timestamp> Capability<T>
impl<T: Timestamp> Capability<T>
Sourcepub fn delayed(&self, new_time: &T) -> Capability<T>
pub fn delayed(&self, new_time: &T) -> Capability<T>
Makes a new capability for a timestamp new_time
greater or equal to the timestamp of
the source capability (self
).
This method panics if self.time
is not less or equal to new_time
.
Sourcepub fn try_delayed(&self, new_time: &T) -> Option<Capability<T>>
pub fn try_delayed(&self, new_time: &T) -> Option<Capability<T>>
Attempts to make a new capability for a timestamp new_time
that is
greater or equal to the timestamp of the source capability (self
).
Returns None
self.time
is not less or equal to new_time
.
Sourcepub fn downgrade(&mut self, new_time: &T)
pub fn downgrade(&mut self, new_time: &T)
Downgrades the capability to one corresponding to new_time
.
This method panics if self.time
is not less or equal to new_time
.
Sourcepub fn try_downgrade(&mut self, new_time: &T) -> Result<(), DowngradeError>
pub fn try_downgrade(&mut self, new_time: &T) -> Result<(), DowngradeError>
Attempts to downgrade the capability to one corresponding to new_time
.
Returns a DowngradeError if self.time
is not less or equal to new_time
.
Trait Implementations§
Source§impl<T: Timestamp> Clone for Capability<T>
impl<T: Timestamp> Clone for Capability<T>
Source§fn clone(&self) -> Capability<T>
fn clone(&self) -> Capability<T>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl<T: Timestamp> Debug for Capability<T>
impl<T: Timestamp> Debug for Capability<T>
Source§impl<T: Timestamp> Deref for Capability<T>
impl<T: Timestamp> Deref for Capability<T>
Source§impl<T: Timestamp> Drop for Capability<T>
impl<T: Timestamp> Drop for Capability<T>
Source§impl<T: Timestamp> Hash for Capability<T>
impl<T: Timestamp> Hash for Capability<T>
Source§impl<T: Timestamp> PartialEq for Capability<T>
impl<T: Timestamp> PartialEq for Capability<T>
Source§impl<T: Timestamp> PartialOrder for Capability<T>
impl<T: Timestamp> PartialOrder for Capability<T>
impl<T: Timestamp> Eq for Capability<T>
Auto Trait Implementations§
impl<T> Freeze for Capability<T>where
T: Freeze,
impl<T> !RefUnwindSafe for Capability<T>
impl<T> !Send for Capability<T>
impl<T> !Sync for Capability<T>
impl<T> Unpin for Capability<T>where
T: Unpin,
impl<T> !UnwindSafe for Capability<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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)