pub enum TextToColumnsResult {
Show 14 variants
WouldChange {
summary: String,
source: String,
spill: Option<String>,
width_upper_bound: usize,
overwritten_cells: Vec<String>,
past_grid_extent: bool,
},
RefusedNotASpreadsheet {
mime_type: String,
},
RefusedShortcut,
RefusedNoVisibleParents,
RefusedSheetNotFound {
title: String,
available: Vec<String>,
},
RefusedInvalidRange {
detail: String,
},
RefusedInvalidDelimiter {
detail: String,
},
Blocked {
operation: DriveOperation,
decided_by: Option<DecidingRule>,
},
RefusedNoLease,
RefusedLeaseExpired,
RefusedLeaseWrongFile,
RefusedLeaseStale,
Changed {
summary: String,
source: String,
spill: Option<String>,
width_upper_bound: usize,
overwritten_cells: Vec<String>,
past_grid_extent: bool,
},
Failed {
detail: String,
},
}Expand description
What happened (or, under --dry-run, would happen).
Variants§
WouldChange
--dry-run, and the gate would allow it.
Fields
summary: StringA human-readable, tense-neutral summary of the effect —
also the request log’s fields_changed. Names the source, the
delimiter, and the upper-bound width and spill span; the
overwrite count and the grid-extent caveat are separate,
tense-varying lines built by describe_lines, so this same
string reads correctly under both Would … and Applied: ….
spill: Option<String>The spill span’s A1 address — the columns to the right of
source a split of width_upper_bound columns would reach.
None when the local split never produces more than one
column, so nothing would be written beyond source.
width_upper_bound: usizeAn upper bound on how many columns the split needs, computed
locally with a naive, non-quote-aware split — never the
server’s real answer, which this crate cannot predict. Under
Delimiter::Auto it is an estimate rather than a bound,
and the rendered output says so
([AUTO_DELIMITER_CAVEAT]).
overwritten_cells: Vec<String>The non-blank cells within the spill span that would be
overwritten, as bare A1 addresses — never their values,
unlike merge-cells’ own discarded_cells (ADR-0083 §6).
Always an upper bound: the API decides for itself how many
columns the split needs, so some of the listed cells may not
actually be touched — and under Delimiter::Auto it picks
the separator too, which can reach cells this list does not
name ([AUTO_DELIMITER_CAVEAT]).
RefusedNotASpreadsheet
The target is not a Google Sheet.
RefusedShortcut
The target is a shortcut, which we do not follow.
RefusedNoVisibleParents
The target has no parents this account can see.
RefusedSheetNotFound
The named sheet does not exist in this workbook.
RefusedInvalidRange
The --sheet/--source pair, or the resolved range, was invalid —
not fully bounded, or spanning more than one column.
RefusedInvalidDelimiter
--custom-delimiter was empty.
Blocked
The folder write-permission gate refused it.
Fields
operation: DriveOperationWhich of [GATE_OPERATIONS] denied first — the union gate
refuses as soon as one of the two does, and which one it was
is the only actionable part of the message.
decided_by: Option<DecidingRule>The rule that decided the refusal, if any.
RefusedNoLease
No --lease was presented, and the deciding rule requires one
(ADR-0080 §9).
RefusedLeaseExpired
The presented lease has expired, or was never a token this ledger knows about.
RefusedLeaseWrongFile
The presented lease is bound to a different file id.
RefusedLeaseStale
The file has moved since the lease’s recorded version — the
staleness check (ADR-0080 §6).
Changed
The mutation succeeded.
Fields
summary: StringThe same tense-neutral summary Self::WouldChange carries,
built by the same call — which is why it reads correctly after
the fact as well as before it.
source: StringSame as Self::WouldChange.
spill: Option<String>Same as Self::WouldChange.
width_upper_bound: usizeSame as Self::WouldChange.
overwritten_cells: Vec<String>Same as Self::WouldChange — read before the mutating call
(the same read serves both paths), so this names what was
overwritten, not a post-hoc guess.
past_grid_extent: boolSame as Self::WouldChange.
Failed
An API or validation error.
Trait Implementations§
Source§impl Clone for TextToColumnsResult
impl Clone for TextToColumnsResult
Source§impl Debug for TextToColumnsResult
impl Debug for TextToColumnsResult
impl Eq for TextToColumnsResult
Source§impl PartialEq for TextToColumnsResult
impl PartialEq for TextToColumnsResult
Source§impl Serialize for TextToColumnsResult
impl Serialize for TextToColumnsResult
impl StructuralPartialEq for TextToColumnsResult
Auto Trait Implementations§
impl Freeze for TextToColumnsResult
impl RefUnwindSafe for TextToColumnsResult
impl Send for TextToColumnsResult
impl Sync for TextToColumnsResult
impl Unpin for TextToColumnsResult
impl UnsafeUnpin for TextToColumnsResult
impl UnwindSafe for TextToColumnsResult
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§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more