pub struct MessagesImageBlock {
pub cache_control: Option<CacheControl>,
pub source: MessagesImageSource,
pub type_: MessagesImageBlockType,
}Expand description
An image content block in a Messages API request.
JSON schema
{
"description": "An image content block in a Messages API request.",
"type": "object",
"required": [
"source",
"type"
],
"properties": {
"cache_control": {
"$ref": "#/definitions/CacheControl"
},
"source": {
"$ref": "#/definitions/MessagesImageSource"
},
"type": {
"description": "Content type identifier. Always `image`.",
"type": "string",
"enum": [
"image"
]
}
}
}Fields§
§cache_control: Option<CacheControl>§source: MessagesImageSource§type_: MessagesImageBlockTypeContent type identifier. Always image.
Trait Implementations§
Source§impl Clone for MessagesImageBlock
impl Clone for MessagesImageBlock
Source§fn clone(&self) -> MessagesImageBlock
fn clone(&self) -> MessagesImageBlock
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 MessagesImageBlock
impl Debug for MessagesImageBlock
Source§impl<'de> Deserialize<'de> for MessagesImageBlock
impl<'de> Deserialize<'de> for MessagesImageBlock
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 From<MessagesImageBlock> for MessagesRequestContentBlock
impl From<MessagesImageBlock> for MessagesRequestContentBlock
Source§fn from(value: MessagesImageBlock) -> Self
fn from(value: MessagesImageBlock) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for MessagesImageBlock
impl RefUnwindSafe for MessagesImageBlock
impl Send for MessagesImageBlock
impl Sync for MessagesImageBlock
impl Unpin for MessagesImageBlock
impl UnsafeUnpin for MessagesImageBlock
impl UnwindSafe for MessagesImageBlock
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