#[non_exhaustive]pub struct TextGroundingMetadata {
pub segments: Vec<Segment>,
pub references: Vec<Reference>,
/* private fields */
}Available on crate features
assistant-service or conversational-search-service or session-service only.Expand description
Grounding details for text sources.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.segments: Vec<Segment>Grounding information for parts of the text.
references: Vec<Reference>References for the grounded text.
Implementations§
Source§impl TextGroundingMetadata
impl TextGroundingMetadata
pub fn new() -> Self
Sourcepub fn set_segments<T, V>(self, v: T) -> Self
pub fn set_segments<T, V>(self, v: T) -> Self
Sourcepub fn set_references<T, V>(self, v: T) -> Self
pub fn set_references<T, V>(self, v: T) -> Self
Sets the value of references.
§Example
ⓘ
use google_cloud_discoveryengine_v1::model::assistant_grounded_content::text_grounding_metadata::Reference;
let x = TextGroundingMetadata::new()
.set_references([
Reference::default()/* use setters */,
Reference::default()/* use (different) setters */,
]);Trait Implementations§
Source§impl Clone for TextGroundingMetadata
impl Clone for TextGroundingMetadata
Source§fn clone(&self) -> TextGroundingMetadata
fn clone(&self) -> TextGroundingMetadata
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 TextGroundingMetadata
impl Debug for TextGroundingMetadata
Source§impl Default for TextGroundingMetadata
impl Default for TextGroundingMetadata
Source§fn default() -> TextGroundingMetadata
fn default() -> TextGroundingMetadata
Returns the “default value” for a type. Read more
Source§impl Message for TextGroundingMetadata
impl Message for TextGroundingMetadata
Source§impl PartialEq for TextGroundingMetadata
impl PartialEq for TextGroundingMetadata
impl StructuralPartialEq for TextGroundingMetadata
Auto Trait Implementations§
impl Freeze for TextGroundingMetadata
impl RefUnwindSafe for TextGroundingMetadata
impl Send for TextGroundingMetadata
impl Sync for TextGroundingMetadata
impl Unpin for TextGroundingMetadata
impl UnwindSafe for TextGroundingMetadata
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