#[non_exhaustive]pub enum TransientRefusal {
CrossesTableCells,
LoadInPlace,
WriteInProgress,
CommitInSeveralPlaces,
RangeOfTransientTextOnly,
LayerOutstanding,
}Expand description
Why the document’s transient edits refused an operation
(DocumentError::TransientEdits). Marked #[non_exhaustive]: match with a _ arm.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
CrossesTableCells
A transient edit whose selection a removal would not take as it stands: one across a
table’s cells, or one holding part of a table and text outside it, which
TextCursor::set_position never leaves but
another cursor’s edit can
(TextCursor::insert_text_transient and
its siblings). Nothing changes.
LoadInPlace
A transient edit while a load in place
(TextDocument::set_djot and its siblings) is still
writing the document. Nothing changes.
WriteInProgress
A transient edit while another write to the document’s store is open, which the
store refuses so that the recorded content the transient edits are made over is
whole. The one write of this document left open across its calls is a load in place,
reported as LoadInPlace before the store is asked; this is the
store’s own refusal of any other. Nothing changes.
CommitInSeveralPlaces
A commit of transient edits made in more than one place, which would replace the
recorded text between them as well
(TextCursor::commit_transient_text).
The transient edits stay as they were.
RangeOfTransientTextOnly
A TextCursor::replace whose range held only
transient text: the revert it begins with took that text away, and nothing is
replaced.
LayerOutstanding
A recorded write that found transient edits outstanding when it began, which the document’s store refuses before anything is written. Every write this crate offers reverts them first, so they were made since, by another thread between that revert and the write. Nothing is recorded, and an open edit block keeps what it holds.
Trait Implementations§
Source§impl Clone for TransientRefusal
impl Clone for TransientRefusal
impl Copy for TransientRefusal
Source§impl Debug for TransientRefusal
impl Debug for TransientRefusal
Source§impl Display for TransientRefusal
impl Display for TransientRefusal
impl Eq for TransientRefusal
Source§impl Error for TransientRefusal
impl Error for TransientRefusal
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl From<TransientWriteRefused> for TransientRefusal
impl From<TransientWriteRefused> for TransientRefusal
Source§fn from(_: TransientWriteRefused) -> Self
fn from(_: TransientWriteRefused) -> Self
The store’s refusal to begin a transient write. Both of its cases are another write in progress on the store: a transient one (which the document’s lock keeps from happening) or a recorded one.
Source§impl PartialEq for TransientRefusal
impl PartialEq for TransientRefusal
impl StructuralPartialEq for TransientRefusal
Auto Trait Implementations§
impl Freeze for TransientRefusal
impl RefUnwindSafe for TransientRefusal
impl Send for TransientRefusal
impl Sync for TransientRefusal
impl Unpin for TransientRefusal
impl UnsafeUnpin for TransientRefusal
impl UnwindSafe for TransientRefusal
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§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.