Gets or sets word-character set.

Namespace: Sgry.Azuki.Highlighter
Assembly: Azuki (in Azuki.dll) Version: 1.7.13.40248

Syntax

C#
public string WordCharSet { get; set; }
Visual Basic
Public Property WordCharSet As String
	Get
	Set

Property Value

Type: String

Remarks

KeywordHighlighter treats a sequence of characters in a word-character set as a word. The word-character set must be an alphabetically sorted character sequence. Setting this property to a character sequence which is not sorted alphabetically, ArgumentException will be thrown. If this property was set to null, KeywordHighlighter uses internally defined default word-character set. Default word-character set is 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz.

Word-character set affects keyword matching process. If a keyword partially matched to a token in a document, KeywordHighlighter checks whether the character at the place where the match ended is included in the word-character set or not. Then if it was NOT a one of the word-character set, KeywordHighlighter determines the token which ends there is a keyword and highlight the token. For example, if word-character set is "abc_" and document is "abc-def abc_def", "abc" of "abc-def" will be highlighted but "abc" of "abc_def" will NOT be highlighted because following character for former one ('-') is not included in the word-character set but one of the latter pattern ('_') is included. Note that if there are keywords that contain characters not included in the word-character set, KeywordHighlighter will not highlight such keywords properly.

Exceptions

ExceptionCondition
System..::..ArgumentException Characters in value are not sorted alphabetically.

See Also