AnalysisHintNode.GetWordlist - метод
Обновлен: Ноябрь 2007
Returns a string array that represents the word list for this analysis hint.
Пространство имен: Microsoft.Ink
Сборка: Microsoft.Ink.Analysis (в Microsoft.Ink.Analysis.dll)
Синтаксис
'Декларация
Public Function GetWordlist As String()
'Применение
Dim instance As AnalysisHintNode
Dim returnValue As String()
returnValue = instance.GetWordlist()
public string[] GetWordlist()
public:
array<String^>^ GetWordlist()
public String[] GetWordlist()
public function GetWordlist() : String[]
Возвращаемое значение
Тип: array<System.String[]
A string array that represents the word list for this analysis hint, or nullссылка null (Nothing в Visual Basic) if no word list is set.
Заметки
To change the hint's word list, use SetWordlist.
Примеры
This example creates a System.Text.StringBuilder, notes, and adds information about all the hints currently attached to the InkAnalyzer, theInkAnalyzerWithHint. For each hint, the hint's name, word list, and recognized string are added to notes.
Dim notes = New System.Text.StringBuilder()
notes.AppendLine("List of all the current AnalysisHintNodes:")
Dim theHint As Microsoft.Ink.AnalysisHintNode
For Each theHint In Me.theInkAnalyzerWithHint.GetAnalysisHints()
notes.AppendLine(" Hint Name: " + theHint.Name)
If 0 < theHint.GetWordlist().Length Then
notes.Append(" - WordList: ")
Dim first As Boolean = True
Dim theWord As String
For Each theWord In theHint.GetWordlist()
If Not first Then
notes.Append(", ")
Else
first = False
End If
notes.AppendFormat("'{0}'", theWord)
Next theWord
notes.AppendLine()
Else
notes.AppendLine(" - No WordList specified")
End If
If String.Empty <> theHint.GetRecognizedString() Then
notes.AppendLine(" - Recognized string: " _
+ theHint.GetRecognizedString())
Else
notes.AppendLine(" - No recognized string.")
End If
notes.AppendLine()
Next theHint
System.Text.StringBuilder notes = new StringBuilder();
notes.AppendLine("List of all the current AnalysisHintNodes:");
foreach (Microsoft.Ink.AnalysisHintNode theHint
in this.theInkAnalyzerWithHint.GetAnalysisHints())
{
notes.AppendLine(" Hint Name: " + theHint.Name);
if (0 < theHint.GetWordlist().Length)
{
notes.Append(" - WordList: ");
bool first = true;
foreach (String theWord in theHint.GetWordlist())
{
if (!first)
{
notes.Append(", ");
}
else
{
first = false;
}
notes.AppendFormat("'{0}'", theWord);
}
notes.AppendLine();
}
else
{
notes.AppendLine(" - No WordList specified");
}
if (string.Empty != theHint.GetRecognizedString())
{
notes.AppendLine(" - Recognized string: "
+ theHint.GetRecognizedString());
}
else
{
notes.AppendLine(" - No recognized string.");
}
notes.AppendLine();
}
Платформы
Windows Vista
Среды .NET Framework и .NET Compact Framework поддерживают не все версии каждой платформы. Поддерживаемые версии перечислены в разделе Требования к системе для .NET Framework.
Сведения о версии
.NET Framework
Поддерживается в версии: 3.0