#[non_exhaustive]pub struct SourceTargetMapping {
pub source_spec: Option<SourceSpec>,
pub target_spec: Option<TargetSpec>,
/* private fields */
}Expand description
Represents one mapping from a source SQL to a target SQL.
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_spec: Option<SourceSpec>The source SQL or the path to it.
target_spec: Option<TargetSpec>The target SQL or the path for it.
Implementations§
Source§impl SourceTargetMapping
impl SourceTargetMapping
pub fn new() -> Self
Sourcepub fn set_source_spec<T>(self, v: T) -> Selfwhere
T: Into<SourceSpec>,
pub fn set_source_spec<T>(self, v: T) -> Selfwhere
T: Into<SourceSpec>,
Sets the value of source_spec.
§Example
ⓘ
use google_cloud_bigquery_migration_v2::model::SourceSpec;
let x = SourceTargetMapping::new().set_source_spec(SourceSpec::default()/* use setters */);Sourcepub fn set_or_clear_source_spec<T>(self, v: Option<T>) -> Selfwhere
T: Into<SourceSpec>,
pub fn set_or_clear_source_spec<T>(self, v: Option<T>) -> Selfwhere
T: Into<SourceSpec>,
Sets or clears the value of source_spec.
§Example
ⓘ
use google_cloud_bigquery_migration_v2::model::SourceSpec;
let x = SourceTargetMapping::new().set_or_clear_source_spec(Some(SourceSpec::default()/* use setters */));
let x = SourceTargetMapping::new().set_or_clear_source_spec(None::<SourceSpec>);Sourcepub fn set_target_spec<T>(self, v: T) -> Selfwhere
T: Into<TargetSpec>,
pub fn set_target_spec<T>(self, v: T) -> Selfwhere
T: Into<TargetSpec>,
Sets the value of target_spec.
§Example
ⓘ
use google_cloud_bigquery_migration_v2::model::TargetSpec;
let x = SourceTargetMapping::new().set_target_spec(TargetSpec::default()/* use setters */);Sourcepub fn set_or_clear_target_spec<T>(self, v: Option<T>) -> Selfwhere
T: Into<TargetSpec>,
pub fn set_or_clear_target_spec<T>(self, v: Option<T>) -> Selfwhere
T: Into<TargetSpec>,
Sets or clears the value of target_spec.
§Example
ⓘ
use google_cloud_bigquery_migration_v2::model::TargetSpec;
let x = SourceTargetMapping::new().set_or_clear_target_spec(Some(TargetSpec::default()/* use setters */));
let x = SourceTargetMapping::new().set_or_clear_target_spec(None::<TargetSpec>);Trait Implementations§
Source§impl Clone for SourceTargetMapping
impl Clone for SourceTargetMapping
Source§fn clone(&self) -> SourceTargetMapping
fn clone(&self) -> SourceTargetMapping
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 SourceTargetMapping
impl Debug for SourceTargetMapping
Source§impl Default for SourceTargetMapping
impl Default for SourceTargetMapping
Source§fn default() -> SourceTargetMapping
fn default() -> SourceTargetMapping
Returns the “default value” for a type. Read more
Source§impl Message for SourceTargetMapping
impl Message for SourceTargetMapping
Source§impl PartialEq for SourceTargetMapping
impl PartialEq for SourceTargetMapping
impl StructuralPartialEq for SourceTargetMapping
Auto Trait Implementations§
impl Freeze for SourceTargetMapping
impl RefUnwindSafe for SourceTargetMapping
impl Send for SourceTargetMapping
impl Sync for SourceTargetMapping
impl Unpin for SourceTargetMapping
impl UnwindSafe for SourceTargetMapping
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