pub struct ImageContentBlock {
pub block_type: String,
pub id: Option<String>,
pub file_id: Option<String>,
pub mime_type: Option<String>,
pub index: Option<BlockIndex>,
pub url: Option<String>,
pub base64: Option<String>,
pub extras: Option<HashMap<String, Value>>,
}Expand description
Image data content block.
Fields§
§block_type: StringType of the content block. Always “image”.
id: Option<String>Content block identifier.
file_id: Option<String>ID of the image file, e.g., from a file storage system.
mime_type: Option<String>MIME type of the image. Required for base64.
index: Option<BlockIndex>Index of block in aggregate response. Used during streaming.
url: Option<String>URL of the image.
base64: Option<String>Data as a base64 string.
extras: Option<HashMap<String, Value>>Provider-specific metadata.
Implementations§
Trait Implementations§
Source§impl Clone for ImageContentBlock
impl Clone for ImageContentBlock
Source§fn clone(&self) -> ImageContentBlock
fn clone(&self) -> ImageContentBlock
Returns a duplicate of the value. Read more
1.0.0 · 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 ImageContentBlock
impl Debug for ImageContentBlock
Source§impl Default for ImageContentBlock
impl Default for ImageContentBlock
Source§impl<'de> Deserialize<'de> for ImageContentBlock
impl<'de> Deserialize<'de> for ImageContentBlock
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
Source§impl PartialEq for ImageContentBlock
impl PartialEq for ImageContentBlock
Source§impl Serialize for ImageContentBlock
impl Serialize for ImageContentBlock
impl StructuralPartialEq for ImageContentBlock
Auto Trait Implementations§
impl Freeze for ImageContentBlock
impl RefUnwindSafe for ImageContentBlock
impl Send for ImageContentBlock
impl Sync for ImageContentBlock
impl Unpin for ImageContentBlock
impl UnwindSafe for ImageContentBlock
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