ITextStructureNavigatorProvider 接口

获取给定 ITextBufferITextStructureNavigator

命名空间:  Microsoft.VisualStudio.Text.Operations
程序集:  Microsoft.VisualStudio.Text.Logic(在 Microsoft.VisualStudio.Text.Logic.dll 中)

语法

声明
Public Interface ITextStructureNavigatorProvider
public interface ITextStructureNavigatorProvider
public interface class ITextStructureNavigatorProvider
type ITextStructureNavigatorProvider =  interface end
public interface ITextStructureNavigatorProvider

ITextStructureNavigatorProvider 类型公开以下成员。

方法

  名称 说明
公共方法 CreateTextStructureNavigator 为指定的 ITextBuffer 创建一个新的 ITextStructureNavigator

页首

备注

这是 MEF 组件部件,应通过以下属性:

[Export(NameSource=typeof(ITextStructureNavigatorProvider))]

您必须提供至少一 ContentTypeAttribute 指定适用的内容类型。

请使用该提供程序,当您实现该类型的内容或语言的时 ITextStructureNavigator ,因此,提供程序创建浏览器的正确类型。 您可以导入 ITextStructureNavigatorSelectorService 获取特定内容类型的一个浏览器。

示例

有关示例中使用该浏览器和浏览器提供程序,请参见 演练:显示 SmartTags

请参阅

参考

Microsoft.VisualStudio.Text.Operations 命名空间