#[non_exhaustive]pub struct CodeModeReceipt {
pub language: Option<CodeModeLanguage>,
pub source_arg: Option<String>,
pub cell_item_id: Option<String>,
pub output_spans: Option<Vec<CodeModeOutputSpan>>,
}Expand description
Code Mode’s details payload.
Every member is absent when it does not apply, never null; an empty
outputSpans list is never served.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.language: Option<CodeModeLanguage>execute, and wait when the producer resolved the originating
execute: the language the cell ran in.
source_arg: Option<String>execute only: the top-level key of the item’s args object whose
value is the cell source. A pointer, never source bytes.
cell_item_id: Option<String>wait only, when the producer resolved it: the itemId of the
execute item that started the cell.
output_spans: Option<Vec<CodeModeOutputSpan>>The public cell-output spans, ascending and non-overlapping; absent when there is no cell body or a hook rewrote the served body.
Implementations§
Source§impl CodeModeReceipt
impl CodeModeReceipt
Sourcepub fn serializes_empty(&self) -> bool
pub fn serializes_empty(&self) -> bool
True when no member would be serialized, so the receipt omits details
entirely.
Trait Implementations§
Source§impl Clone for CodeModeReceipt
impl Clone for CodeModeReceipt
Source§impl Debug for CodeModeReceipt
impl Debug for CodeModeReceipt
Source§impl Default for CodeModeReceipt
impl Default for CodeModeReceipt
Source§impl<'de> Deserialize<'de> for CodeModeReceipt
impl<'de> Deserialize<'de> for CodeModeReceipt
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for CodeModeReceipt
Source§impl PartialEq for CodeModeReceipt
impl PartialEq for CodeModeReceipt
Source§impl Serialize for CodeModeReceipt
impl Serialize for CodeModeReceipt
impl StructuralPartialEq for CodeModeReceipt
Auto Trait Implementations§
impl Forget for CodeModeReceipt
impl Freeze for CodeModeReceipt
impl Move for CodeModeReceipt
impl RefUnwindSafe for CodeModeReceipt
impl Send for CodeModeReceipt
impl Sync for CodeModeReceipt
impl Unpin for CodeModeReceipt
impl UnsafeUnpin for CodeModeReceipt
impl UnwindSafe for CodeModeReceipt
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