#[non_exhaustive]pub struct CompletionDataInputConfig {
pub source: Option<Source>,
/* private fields */
}Expand description
The input config source for completion data.
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.source: Option<Source>The source of the input.
Supported BigQuerySource.data_schema values for suggestions imports:
suggestions(default): One JSON completion suggestion per line.denylist: One JSON deny suggestion per line.allowlist: One JSON allow suggestion per line.
Implementations§
Source§impl CompletionDataInputConfig
impl CompletionDataInputConfig
pub fn new() -> Self
Sourcepub fn set_source<T: Into<Option<Source>>>(self, v: T) -> Self
pub fn set_source<T: Into<Option<Source>>>(self, v: T) -> Self
Sets the value of source.
Note that all the setters affecting source are mutually
exclusive.
§Example
ⓘ
use google_cloud_retail_v2::model::BigQuerySource;
let x = CompletionDataInputConfig::new().set_source(Some(
google_cloud_retail_v2::model::completion_data_input_config::Source::BigQuerySource(BigQuerySource::default().into())));Sourcepub fn big_query_source(&self) -> Option<&Box<BigQuerySource>>
pub fn big_query_source(&self) -> Option<&Box<BigQuerySource>>
The value of source
if it holds a BigQuerySource, None if the field is not set or
holds a different branch.
Sourcepub fn set_big_query_source<T: Into<Box<BigQuerySource>>>(self, v: T) -> Self
pub fn set_big_query_source<T: Into<Box<BigQuerySource>>>(self, v: T) -> Self
Sets the value of source
to hold a BigQuerySource.
Note that all the setters affecting source are
mutually exclusive.
§Example
ⓘ
use google_cloud_retail_v2::model::BigQuerySource;
let x = CompletionDataInputConfig::new().set_big_query_source(BigQuerySource::default()/* use setters */);
assert!(x.big_query_source().is_some());Trait Implementations§
Source§impl Clone for CompletionDataInputConfig
impl Clone for CompletionDataInputConfig
Source§fn clone(&self) -> CompletionDataInputConfig
fn clone(&self) -> CompletionDataInputConfig
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 CompletionDataInputConfig
impl Debug for CompletionDataInputConfig
Source§impl Default for CompletionDataInputConfig
impl Default for CompletionDataInputConfig
Source§fn default() -> CompletionDataInputConfig
fn default() -> CompletionDataInputConfig
Returns the “default value” for a type. Read more
Source§impl Message for CompletionDataInputConfig
impl Message for CompletionDataInputConfig
impl StructuralPartialEq for CompletionDataInputConfig
Auto Trait Implementations§
impl Freeze for CompletionDataInputConfig
impl RefUnwindSafe for CompletionDataInputConfig
impl Send for CompletionDataInputConfig
impl Sync for CompletionDataInputConfig
impl Unpin for CompletionDataInputConfig
impl UnwindSafe for CompletionDataInputConfig
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