pub struct CachedContent {
pub name: String,
pub model: Model,
pub create_time: OffsetDateTime,
pub update_time: OffsetDateTime,
pub usage_metadata: CacheUsageMetadata,
pub expiration: CacheExpirationResponse,
pub display_name: Option<String>,
pub contents: Option<Vec<Content>>,
pub tools: Option<Vec<Tool>>,
pub system_instruction: Option<Content>,
pub tool_config: Option<ToolConfig>,
}
Expand description
Cached content resource returned by the API (with all server-provided fields).
Fields§
§name: String
The resource name of the cached content. Format: cachedContents/{id}
model: Model
The name of the model used for cached content.
create_time: OffsetDateTime
Output only. Creation time of the cached content.
update_time: OffsetDateTime
Output only. Last update time of the cached content.
usage_metadata: CacheUsageMetadata
Output only. Usage metadata for the cached content.
expiration: CacheExpirationResponse
Expiration information for the cached content.
display_name: Option<String>
The user-generated display name (if provided).
contents: Option<Vec<Content>>
The cached contents (may be omitted in some API responses for size).
tools: Option<Vec<Tool>>
The cached tools (may be omitted in some API responses for size).
system_instruction: Option<Content>
The cached system instruction (may be omitted in some API responses for size).
tool_config: Option<ToolConfig>
The cached tool config (may be omitted in some API responses for size).
Trait Implementations§
Source§impl Clone for CachedContent
impl Clone for CachedContent
Source§fn clone(&self) -> CachedContent
fn clone(&self) -> CachedContent
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 CachedContent
impl Debug for CachedContent
Source§impl<'de> Deserialize<'de> for CachedContent
impl<'de> Deserialize<'de> for CachedContent
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 CachedContent
impl PartialEq for CachedContent
Source§impl Serialize for CachedContent
impl Serialize for CachedContent
impl StructuralPartialEq for CachedContent
Auto Trait Implementations§
impl Freeze for CachedContent
impl RefUnwindSafe for CachedContent
impl Send for CachedContent
impl Sync for CachedContent
impl Unpin for CachedContent
impl UnwindSafe for CachedContent
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