#[non_exhaustive]pub struct BatchDocumentInputConfig {
pub source: Option<Source>,
/* private fields */
}Expand description
Input configuration for BatchTranslateDocument request.
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>Specify the input.
Implementations§
Source§impl BatchDocumentInputConfig
impl BatchDocumentInputConfig
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_translation_v3::model::GcsSource;
let x = BatchDocumentInputConfig::new().set_source(Some(
google_cloud_translation_v3::model::batch_document_input_config::Source::GcsSource(GcsSource::default().into())));Sourcepub fn gcs_source(&self) -> Option<&Box<GcsSource>>
pub fn gcs_source(&self) -> Option<&Box<GcsSource>>
The value of source
if it holds a GcsSource, None if the field is not set or
holds a different branch.
Sourcepub fn set_gcs_source<T: Into<Box<GcsSource>>>(self, v: T) -> Self
pub fn set_gcs_source<T: Into<Box<GcsSource>>>(self, v: T) -> Self
Sets the value of source
to hold a GcsSource.
Note that all the setters affecting source are
mutually exclusive.
§Example
ⓘ
use google_cloud_translation_v3::model::GcsSource;
let x = BatchDocumentInputConfig::new().set_gcs_source(GcsSource::default()/* use setters */);
assert!(x.gcs_source().is_some());Trait Implementations§
Source§impl Clone for BatchDocumentInputConfig
impl Clone for BatchDocumentInputConfig
Source§fn clone(&self) -> BatchDocumentInputConfig
fn clone(&self) -> BatchDocumentInputConfig
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 BatchDocumentInputConfig
impl Debug for BatchDocumentInputConfig
Source§impl Default for BatchDocumentInputConfig
impl Default for BatchDocumentInputConfig
Source§fn default() -> BatchDocumentInputConfig
fn default() -> BatchDocumentInputConfig
Returns the “default value” for a type. Read more
Source§impl Message for BatchDocumentInputConfig
impl Message for BatchDocumentInputConfig
Source§impl PartialEq for BatchDocumentInputConfig
impl PartialEq for BatchDocumentInputConfig
impl StructuralPartialEq for BatchDocumentInputConfig
Auto Trait Implementations§
impl Freeze for BatchDocumentInputConfig
impl RefUnwindSafe for BatchDocumentInputConfig
impl Send for BatchDocumentInputConfig
impl Sync for BatchDocumentInputConfig
impl Unpin for BatchDocumentInputConfig
impl UnsafeUnpin for BatchDocumentInputConfig
impl UnwindSafe for BatchDocumentInputConfig
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