#[non_exhaustive]pub struct ReplicatedVoiceConfig {
pub mime_type: String,
pub voice_sample_audio: Bytes,
/* private fields */
}Available on crate features
llm-utility-service or prediction-service only.Expand description
The configuration for the replicated voice to use.
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.mime_type: StringOptional. The mimetype of the voice sample. The only currently supported
value is audio/wav. This represents 16-bit signed little-endian wav data,
with a 24kHz sampling rate. mime_type will default to audio/wav if not
set.
voice_sample_audio: BytesOptional. The sample of the custom voice.
Implementations§
Source§impl ReplicatedVoiceConfig
impl ReplicatedVoiceConfig
pub fn new() -> Self
Sourcepub fn set_mime_type<T: Into<String>>(self, v: T) -> Self
pub fn set_mime_type<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_voice_sample_audio<T: Into<Bytes>>(self, v: T) -> Self
pub fn set_voice_sample_audio<T: Into<Bytes>>(self, v: T) -> Self
Sets the value of voice_sample_audio.
§Example
ⓘ
let x = ReplicatedVoiceConfig::new().set_voice_sample_audio(bytes::Bytes::from_static(b"example"));Trait Implementations§
Source§impl Clone for ReplicatedVoiceConfig
impl Clone for ReplicatedVoiceConfig
Source§fn clone(&self) -> ReplicatedVoiceConfig
fn clone(&self) -> ReplicatedVoiceConfig
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 ReplicatedVoiceConfig
impl Debug for ReplicatedVoiceConfig
Source§impl Default for ReplicatedVoiceConfig
impl Default for ReplicatedVoiceConfig
Source§fn default() -> ReplicatedVoiceConfig
fn default() -> ReplicatedVoiceConfig
Returns the “default value” for a type. Read more
Source§impl Message for ReplicatedVoiceConfig
impl Message for ReplicatedVoiceConfig
Source§impl PartialEq for ReplicatedVoiceConfig
impl PartialEq for ReplicatedVoiceConfig
impl StructuralPartialEq for ReplicatedVoiceConfig
Auto Trait Implementations§
impl !Freeze for ReplicatedVoiceConfig
impl RefUnwindSafe for ReplicatedVoiceConfig
impl Send for ReplicatedVoiceConfig
impl Sync for ReplicatedVoiceConfig
impl Unpin for ReplicatedVoiceConfig
impl UnwindSafe for ReplicatedVoiceConfig
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