#[non_exhaustive]pub struct VoiceConfig {
pub voice_config: Option<VoiceConfig>,
/* private fields */
}Available on crate features
llm-utility-service or prediction-service only.Expand description
Configuration for a voice.
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.voice_config: Option<VoiceConfig>The configuration for the speaker to use.
Implementations§
Source§impl VoiceConfig
impl VoiceConfig
pub fn new() -> Self
Sourcepub fn set_voice_config<T: Into<Option<VoiceConfig>>>(self, v: T) -> Self
pub fn set_voice_config<T: Into<Option<VoiceConfig>>>(self, v: T) -> Self
Sets the value of voice_config.
Note that all the setters affecting voice_config are mutually
exclusive.
§Example
ⓘ
use google_cloud_aiplatform_v1::model::PrebuiltVoiceConfig;
let x = VoiceConfig::new().set_voice_config(Some(
google_cloud_aiplatform_v1::model::voice_config::VoiceConfig::PrebuiltVoiceConfig(PrebuiltVoiceConfig::default().into())));Sourcepub fn prebuilt_voice_config(&self) -> Option<&Box<PrebuiltVoiceConfig>>
pub fn prebuilt_voice_config(&self) -> Option<&Box<PrebuiltVoiceConfig>>
The value of voice_config
if it holds a PrebuiltVoiceConfig, None if the field is not set or
holds a different branch.
Sourcepub fn set_prebuilt_voice_config<T: Into<Box<PrebuiltVoiceConfig>>>(
self,
v: T,
) -> Self
pub fn set_prebuilt_voice_config<T: Into<Box<PrebuiltVoiceConfig>>>( self, v: T, ) -> Self
Sets the value of voice_config
to hold a PrebuiltVoiceConfig.
Note that all the setters affecting voice_config are
mutually exclusive.
§Example
ⓘ
use google_cloud_aiplatform_v1::model::PrebuiltVoiceConfig;
let x = VoiceConfig::new().set_prebuilt_voice_config(PrebuiltVoiceConfig::default()/* use setters */);
assert!(x.prebuilt_voice_config().is_some());
assert!(x.replicated_voice_config().is_none());Sourcepub fn replicated_voice_config(&self) -> Option<&Box<ReplicatedVoiceConfig>>
pub fn replicated_voice_config(&self) -> Option<&Box<ReplicatedVoiceConfig>>
The value of voice_config
if it holds a ReplicatedVoiceConfig, None if the field is not set or
holds a different branch.
Sourcepub fn set_replicated_voice_config<T: Into<Box<ReplicatedVoiceConfig>>>(
self,
v: T,
) -> Self
pub fn set_replicated_voice_config<T: Into<Box<ReplicatedVoiceConfig>>>( self, v: T, ) -> Self
Sets the value of voice_config
to hold a ReplicatedVoiceConfig.
Note that all the setters affecting voice_config are
mutually exclusive.
§Example
ⓘ
use google_cloud_aiplatform_v1::model::ReplicatedVoiceConfig;
let x = VoiceConfig::new().set_replicated_voice_config(ReplicatedVoiceConfig::default()/* use setters */);
assert!(x.replicated_voice_config().is_some());
assert!(x.prebuilt_voice_config().is_none());Trait Implementations§
Source§impl Clone for VoiceConfig
impl Clone for VoiceConfig
Source§fn clone(&self) -> VoiceConfig
fn clone(&self) -> VoiceConfig
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 VoiceConfig
impl Debug for VoiceConfig
Source§impl Default for VoiceConfig
impl Default for VoiceConfig
Source§fn default() -> VoiceConfig
fn default() -> VoiceConfig
Returns the “default value” for a type. Read more
Source§impl Message for VoiceConfig
impl Message for VoiceConfig
Source§impl PartialEq for VoiceConfig
impl PartialEq for VoiceConfig
impl StructuralPartialEq for VoiceConfig
Auto Trait Implementations§
impl Freeze for VoiceConfig
impl RefUnwindSafe for VoiceConfig
impl Send for VoiceConfig
impl Sync for VoiceConfig
impl Unpin for VoiceConfig
impl UnwindSafe for VoiceConfig
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