Microsoft.VisualStudio.Text.Configuration Namespace

Interfaces

IWordPatternBroker

Utility which selects the appropriate IWordPatternProviderFactory for a given SnapshotPoint, gets its IWordPatternProvider and calls GetWordPatternRegexAsync(SnapshotPoint, CancellationToken)

IWordPatternProvider

Provides the Word Pattern which determines boundaries between words. Instance of this type can be obtained by importing IWordPatternProviderFactory.

IWordPatternProviderFactory

Creates IWordPatternProvider applicable to an ITextBuffer.

This is a MEF component and should be exported with [ContentType] and [Name] attributes and optional [Order] attribute. An instance of IWordPatternProviderFactory is selected by matching declared ContentType to content type of location where IWordPatternProvider is needed, and then by declared Order with Order of other applicable components.

[Export(typeof(IWordPatternProviderFactory))]
[Name(nameof(IWordPatternProviderFactory))]
[ContentType("text")]
public class MyWordPatternProviderFactory : IWordPatternProviderFactory