Assembly: Azuki (in Azuki.dll) Version: 1.7.13.40248
Syntax
C# |
---|
public void AddKeywordSet( string[] keywords, CharClass klass, bool ignoreCase ) |
Visual Basic |
---|
Public Sub AddKeywordSet ( keywords As String(), klass As CharClass, ignoreCase As Boolean ) |
Parameters
- keywords
- Type: array<System..::..String>[]()[][]
Sorted array of keywords.
- klass
- Type: Sgry.Azuki..::..CharClass
Char-class to be applied to the keyword set.
- ignoreCase
- Type: System..::..Boolean
Whether case of the keywords should be ignored or not.
Remarks
This method registers a set of keywords to be highlighted.
The keywords stored in keywords parameter will be highlighted as a character class specified by klass parameter. Please ensure that keywords in keywords parameter must be alphabetically sorted. If they are not sorted, ArgumentException will be thrown.
If ignoreCase is true, KeywordHighlighter ignores case of all given keywords on matching. Note that if ignoreCase is true, all characters of keywords must be in lower case otherwise keywords may not be highlighted properly.
If other character must be considered as a part of keyword, use WordCharSet property.
Exceptions
Exception | Condition |
---|---|
System..::..ArgumentException | Parameter 'keywords' are not sorted alphabetically. |
System..::..ArgumentNullException | Parameter 'keywords' is null. |