IStemmer::Init Method
Initializes the stemmer.
Syntax
HRESULT Init( ULONG ulMaxTokenSize, BOOL pfLicense );
Parameters
- ulMaxTokenSize
[in] Maximum number of characters for words that are added to the WordFormSink. Words that exceed this limit may be truncated.- pfLicense
[out] Pointer to an output variable that receives a flag that indicates where there are license restrictions for this IStemmer implementation. TRUE indicates that the stemmer is restricted to authorized use only. FALSE indicates that this IStemmer implementation can be used freely.
Return Value
Returns one of the following values.
LANGUAGE_E_DATABASE_NOT_FOUND One of the components for word breaking cannot be located. E_INVALIDARG Invalid argument. The pfLicense parameter is NULL. E_FAIL Unsuccessful completion. S_OK Successful completion.
Remarks
You must initialize the stemmer. It is called before any other method of IStemmer. If pfLicense is TRUE, and if you want more information about possible license restrictions, call the IStemmer::GetLicenseToUse method.
See Also
Implementing a Stemmer, Language Resource Samples, Secure Code Practices, WordFormSink