ITfFnGetSAPIObject interface
The ITfFnGetSAPIObject interface is implemented by the Speech API (SAPI) text service. This interface is used by the TSF manager or a client (application or other text service) to obtain various SAPI objects.
A client obtains an instance of this interface by obtaining the ITfFunctionProvider for the SAPI text service and calling ITfFunctionProvider::GetFunction with IID_ITfFnGetSAPIObject.
Members
The ITfFnGetSAPIObject interface inherits from the IUnknown interface. ITfFnGetSAPIObject also has these types of members:
Methods
The ITfFnGetSAPIObject interface has these methods.
| Method | Description |
|---|---|
| Get |
Obtains a specified SAPI object. |
Examples
HRESULT hr; ITfFunctionProvider *pFuncProv; hr = pThreadMgr->GetFunctionProvider(CLSID_SapiLayr, &pFuncProv); if(SUCCEEDED(hr)) { ITfFnGetSAPIObject *pGetSAPIObject; hr = pFuncProv->GetFunction(GUID_NULL, IID_ITfFnGetSAPIObject, (IUnknown**)&pGetSAPIObject); if(SUCCEEDED(hr)) { IUnknown *punk; hr = pGetSAPIObject->Get(GETIF_RECOGNIZER, &punk); if(S_OK == hr) //Return S_FALSE if the object cannot be obtained. { punk->Release(); } pGetSAPIObject->Release(); } pFuncProv->Release(); }
Requirements
|
Minimum supported client |
Windows 2000 Professional [desktop apps | Windows Store apps] |
|---|---|
|
Minimum supported server |
Windows 2000 Server [desktop apps | Windows Store apps] |
|
Redistributable |
TSF 1.0 on Windows 2000 Professional |
|
Header |
|
|
IDL |
|
|
DLL |
|