Dela via


WordSegment Class

Definition

Represents a word from your provided text.

Words in this class do not include trailing whitespace or punctuation. This class can also expose alternate forms of words, and normalized numbers, currencies, dates, and times.

public ref class WordSegment sealed
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class WordSegment final
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class WordSegment
Public NotInheritable Class WordSegment
Inheritance
Object Platform::Object IInspectable WordSegment
Attributes

Windows requirements

Device family
Windows 10 (introduced in 10.0.10240.0 - for Xbox, see UWP features that aren't yet supported on Xbox)
API contract
Windows.Foundation.UniversalApiContract (introduced in v1.0)

Properties

AlternateForms

Gets the alternate forms (if any) associated with the current word.

Alternate forms are loosely associated with the current word. An alternate form may encompass less text, more text, or the same text as the original word.

SourceTextSegment

Gets the TextSegment that identifies the source text's sub-string that is a word.

Text

Gets the text of the word identified by this WordSegment object.

Applies to