Struct chlorate::SodaBuilder [−][src]
Implementations
impl SodaBuilder
[src]
pub fn new() -> SodaBuilder
[src]
pub fn channel_count(&mut self, channel_count: u32) -> &mut SodaBuilder
[src]
Number of channels in RAW audio that will be provided to SODA.
pub fn sample_rate(&mut self, sample_rate: u32) -> &mut SodaBuilder
[src]
Maximum size of buffer to use in PipeStream. By default, is 0, which means unlimited.
pub fn max_buffer_bytes(&mut self, max_buffer_bytes: u32) -> &mut SodaBuilder
[src]
Maximum size of buffer to use in PipeStream. By default, is 0, which means unlimited.
pub fn simulate_realtime_testonly(
&mut self,
simulate_realtime_testonly: bool
) -> &mut SodaBuilder
[src]
&mut self,
simulate_realtime_testonly: bool
) -> &mut SodaBuilder
If set to true, forces the audio provider to simulate realtime audio provision. This only makes sense during testing, to simulate realtime audio providing from a big chunk of audio. This slows down audio provided to SODA to a maximum of real-time, which means more accurate endpointer behavior, but is unsuitable for execution in real production environments. Set with caution!
pub fn language_pack_directory(
&mut self,
language_pack_directory: String
) -> &mut SodaBuilder
[src]
&mut self,
language_pack_directory: String
) -> &mut SodaBuilder
Directory of the language pack to use.
pub fn api_key(&mut self, api_key: String) -> &mut SodaBuilder
[src]
API key used for call verification.
pub fn recognition_mode(
&mut self,
recognition_mode: RecognitionMode
) -> &mut SodaBuilder
[src]
&mut self,
recognition_mode: RecognitionMode
) -> &mut SodaBuilder
What kind of recognition to execute here. Impacts model usage.
pub fn reset_on_final_result(
&mut self,
reset_on_final_result: bool
) -> &mut SodaBuilder
[src]
&mut self,
reset_on_final_result: bool
) -> &mut SodaBuilder
Whether terse_processor should force a new session after every final recognition result. This will cause the terse processor to stop processing new audio once an endpoint event is detected and wait for it to generate a final event using audio up to the endpoint. This will cause processing bursts when a new session starts.
pub fn include_timing_metrics(
&mut self,
include_timing_metrics: bool
) -> &mut SodaBuilder
[src]
&mut self,
include_timing_metrics: bool
) -> &mut SodaBuilder
Whether to populate the timing_metrics field on Recognition and Endpoint events.
pub fn enable_lang_id(&mut self, enable_lang_id: bool) -> &mut SodaBuilder
[src]
Whether or not to request lang id events.
pub fn build<'soda>(
&mut self,
callback: impl Fn(SodaResponse) + Send + Sync + 'soda
) -> SodaClient<'soda>
[src]
&mut self,
callback: impl Fn(SodaResponse) + Send + Sync + 'soda
) -> SodaClient<'soda>
Consumes SodaBuilder
to create SodaClient
.
Trait Implementations
impl Default for SodaBuilder
[src]
fn default() -> SodaBuilder
[src]
Auto Trait Implementations
impl RefUnwindSafe for SodaBuilder
impl Send for SodaBuilder
impl Sync for SodaBuilder
impl Unpin for SodaBuilder
impl UnwindSafe for SodaBuilder
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,