/// Creates an instance of the speech config with specified host and subscription.
/// This method is intended only for users who use a non-default service host. Standard resource path will be assumed.
/// For services with a non-standard resource path or no path at all, use FromEndpoint instead.
/// Note: Query parameters are not allowed in the host URI and must be set by other APIs.
/// Note: To use an authorization token with host, use NewSpeechConfigFromHost,
/// and then call SetAuthorizationToken() on the created SpeechConfig instance.
Creates an instance of the speech config with specified host and subscription.
This method is intended only for users who use a non-default service host. Standard resource path will be assumed.
For services with a non-standard resource path or no path at all, use FromEndpoint instead.
Note: Query parameters are not allowed in the host URI and must be set by other APIs.
Note: To use an authorization token with host, use NewSpeechConfigFromHost,
and then call SetAuthorizationToken() on the created SpeechConfig instance.
Creates an instance of the speech config with specified host and subscription . This method is intended only for users who use a non - default service host . Standard resource path will be assumed . For services with a non - standard resource path or no path at all use FromEndpoint instead . Note : Query parameters are not allowed in the host URI and must be set by other APIs . Note : To use an authorization token with host use NewSpeechConfigFromHost and then call SetAuthorizationToken () on the created SpeechConfig instance .
pub fn from_host_with_subscription<S>(host: S, subscription: S) -> Result<SpeechConfig>
    where
        S: Into<Vec<u8>>,
    {
        let c_host = CString::new(host)?;
        let c_subscription = CString::new(subscription)?;
        unsafe {
            let mut handle: SPXSPEECHCONFIGHANDLE = MaybeUninit::uninit().assume_init();
            let ret =
                speech_config_from_host(&mut handle, c_host.as_ptr(), c_subscription.as_ptr());
            convert_err(ret, "SpeechConfig::from_host_with_subscription error")?;
            SpeechConfig::from_handle(handle)
        }
    }
pub fn from_host_with_subscription < S > ( host : S , subscription : S ) -> Result < SpeechConfig > where S : Into < Vec < u8 > > , { let c_host = CString :: new ( host ) ? ; let c_subscription = CString :: new ( subscription ) ? ; unsafe { let mut handle : SPXSPEECHCONFIGHANDLE = MaybeUninit :: uninit ( ) . assume_init ( ) ; let ret = speech_config_from_host ( & mut handle , c_host . as_ptr ( ) , c_subscription . as_ptr ( ) ) ; convert_err ( ret , " " ) ? ; SpeechConfig :: from_handle ( handle ) } }
Creates an instance of the speech config with specified host and subscription.
Creates an instance of the speech config with specified host and subscription .
host
S
subscription
S