IWordSink::PutWord method
Puts a word and its position in the IWordSink object.
HRESULT PutWord(
[in] ULONG cwc,
[in] const WCHAR *pwcInBuf,
[in] ULONG cwcSrcLen,
[in] ULONG cwcSrcPos
);
-
cwc [in]
-
The number of characters in pwcInBuf.
-
pwcInBuf [in]
-
A pointer to a buffer that contains an alternative form of a word from the source text. This parameter is not modified by PutWord. You can pass the pTextSource parameter from IWordBreaker::BreakText as appropriate.
-
cwcSrcLen [in]
-
The number of characters in the source text buffer (indicated by the pTextSource parameter to IWordBreaker::BreakText) that correspond to the word contained in pwcInBuf.
-
cwcSrcPos [in]
-
The starting position of the word in pwcInBuf in the source text buffer (indicated by the pTextSource parameter to IWordBreaker::BreakText).
This method can return one of these values.
Return code | Description |
---|---|
|
The operation was completed successfully. Also indicates that no more text is available to refill the buffer. |
|
Value of cwc is larger than the value for ulMaxTokenSize that is specified in IWordBreaker::Init. |
We recommend that the IWordSink::PutWord method always contain the original word as found in pTextSource. Alternative forms of the word are passed to WordSink by using IWordSink::PutAltWord. We also recommend that the words in pwcInBuf match the source text as closely as possible. For example, retain capitalization and accents where possible.
This call must be made for every word retrieved from pTextSource except those for which the IWordSink::PutAltWord call was made. The word is terminated with an EOW character when it is saved to the WordSink.
Requirement | Value |
---|---|
Minimum supported client |
Windows 2000 Professional [desktop apps only] |
Minimum supported server |
Windows 2000 Server [desktop apps only] |
Header |
|