pub enum ContentRef {
Inline {
value: Value,
},
FileRef {
path: PathBuf,
mime: Option<String>,
size_hint: Option<u64>,
},
}Expand description
How content travels — inline value or file path. Streaming is not carried as its own variant in this iteration.
The SpawnerAdapter picks the appropriate variant at the boundary. When
metadata is unavailable it is acceptable to fall back to Inline with the
raw value, prioritising basic functionality over metadata fidelity.
Variants§
Inline
Inline JSON. Kilobyte-scale, the default for structured data.
FileRef
File-path handoff for large / binary / artifact content. File ownership and cleanup belong to the engine side (carry); the spawner only hands the path over.
Implementations§
Source§impl ContentRef
impl ContentRef
Sourcepub fn inline_text(text: impl Into<String>) -> Self
pub fn inline_text(text: impl Into<String>) -> Self
Wrap raw text as an Inline content ref (the common path for a
ProcessSpawner running in plain mode).
Trait Implementations§
Source§impl Clone for ContentRef
impl Clone for ContentRef
Source§fn clone(&self) -> ContentRef
fn clone(&self) -> ContentRef
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ContentRef
impl Debug for ContentRef
Source§impl<'de> Deserialize<'de> for ContentRef
impl<'de> Deserialize<'de> for ContentRef
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
Auto Trait Implementations§
impl Freeze for ContentRef
impl RefUnwindSafe for ContentRef
impl Send for ContentRef
impl Sync for ContentRef
impl Unpin for ContentRef
impl UnsafeUnpin for ContentRef
impl UnwindSafe for ContentRef
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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>
Converts
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>
Converts
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