Share via


ContextNodeType.AnalysisHint Field

Represents the type of node that provides additional context information for a region to the InkAnalyzer to improve analysis results.

Namespace:  Microsoft.Ink
Assembly:  Microsoft.Ink.Analysis (in Microsoft.Ink.Analysis.dll)

Syntax

'Declaration
Public Shared ReadOnly AnalysisHint As Guid
'Usage
Dim value As Guid 

value = ContextNodeType.AnalysisHint
public static readonly Guid AnalysisHint
public:
static initonly Guid AnalysisHint
public static final var AnalysisHint : Guid

Remarks

The Guid value for this ContextNodeType field is b3e85327-34d8-4a53-9bed-c4aa612428d3.

Examples

The following example finds all WritingRegionNode objects in the node tree of an InkAnalyzer, theInkAnalyzerWithHint. The example then puts those that are linked to an AnalysisHintNode with a Factoid of "IS_DATE_FULLDATE" into a ContextNodeCollection, writingRegionsWithFactoids.

Dim writingRegionsWithFactoids As _
    New ContextNodeCollection(Me.theInkAnalyzerWithHint)
Dim allWritingRegions As ContextNodeCollection = _
    Me.theInkAnalyzerWithHint.FindNodesOfType( _
        Microsoft.Ink.ContextNodeType.WritingRegion)
Dim writingRegion As WritingRegionNode
For Each writingRegion In allWritingRegions
    ' See if they are linked to any factoid 
    Dim link As ContextLink
    For Each link In writingRegion.Links
        If link.SourceNode.Type = ContextNodeType.AnalysisHint Then 
            Dim hint As AnalysisHintNode = _
                CType(link.SourceNode, AnalysisHintNode)
            If hint.Factoid = "IS_DATE_FULLDATE" Then
                writingRegionsWithFactoids.Add(writingRegion)
            End If 
        End If 
    Next link
Next writingRegion
ContextNodeCollection writingRegionsWithFactoids = 
    new ContextNodeCollection(this.theInkAnalyzerWithHint);
ContextNodeCollection allWritingRegions =
    this.theInkAnalyzerWithHint.FindNodesOfType(Microsoft.Ink.ContextNodeType.WritingRegion);
foreach (WritingRegionNode writingRegion in allWritingRegions)
{
    // See if they are linked to any factoid 
    foreach (ContextLink link in writingRegion.Links)
    {
        if (link.SourceNode.Type == ContextNodeType.AnalysisHint)
        {
            AnalysisHintNode hint = (AnalysisHintNode) link.SourceNode;
            if (hint.Factoid == "IS_DATE_FULLDATE")
            {
                writingRegionsWithFactoids.Add(writingRegion);
            }
        }
    }
}

Platforms

Windows 7, Windows Vista, Windows Server 2008 R2, Windows Server 2008

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Version Information

.NET Framework

Supported in: 3.0

See Also

Reference

ContextNodeType Class

ContextNodeType Members

Microsoft.Ink Namespace

Microsoft.Ink.AnalysisHintNode