pub struct GeminiImageReads { /* private fields */ }Expand description
Retains completed reads and an active resource body. Bytes are counted as each chunk arrives; cancellation resumes that same body without a new read.
Implementations§
Source§impl GeminiImageReads
impl GeminiImageReads
Sourcepub async fn materialize<R: ResourceAccess>(
&mut self,
input: &GenerateContentResponseBody,
resources: &GenerationResources<'_, R>,
) -> Result<GenerateContentResponseBody, TransformError>
pub async fn materialize<R: ResourceAccess>( &mut self, input: &GenerateContentResponseBody, resources: &GenerationResources<'_, R>, ) -> Result<GenerateContentResponseBody, TransformError>
Returns a separate inline conversion view; original fileData and its signature stay in retained progress for exact scoped replay.
Source§impl GeminiImageReads
impl GeminiImageReads
pub fn bytes_read(&self) -> u64
pub fn attempted_reads(&self) -> usize
pub fn images(&self) -> impl Iterator<Item = &MaterializedImage>
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for GeminiImageReads
impl !RefUnwindSafe for GeminiImageReads
impl !Sync for GeminiImageReads
impl !UnwindSafe for GeminiImageReads
impl Send for GeminiImageReads
impl Unpin for GeminiImageReads
impl UnsafeUnpin for GeminiImageReads
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