IAnnotationDictionary 接口

表示可以与 SharePoint 工具对象模型中的某些对象相关联的自定义数据对象的字典。

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

语法

声明
Public Interface IAnnotationDictionary _
    Inherits IDictionary(Of Object, Object), ICollection(Of KeyValuePair(Of Object, Object)),  _
    IEnumerable(Of KeyValuePair(Of Object, Object)), IEnumerable
public interface IAnnotationDictionary : IDictionary<Object, Object>, 
    ICollection<KeyValuePair<Object, Object>>, IEnumerable<KeyValuePair<Object, Object>>, 
    IEnumerable

IAnnotationDictionary 类型公开以下成员。

属性

  名称 说明
公共属性 Count 获取 ICollection<T> 中包含的元素数。 (继承自 ICollection<KeyValuePair<Object, Object>>。)
公共属性 IsReadOnly 获取一个值,该值指示 ICollection<T> 是否为只读。 (继承自 ICollection<KeyValuePair<Object, Object>>。)
公共属性 Item 获取或设置具有指定键的元素。 (继承自 IDictionary<Object, Object>。)
公共属性 Keys 获取包含 IDictionary<TKey, TValue> 的键的 ICollection<T>。 (继承自 IDictionary<Object, Object>。)
公共属性 Values 获取包含 IDictionary<TKey, TValue> 中的值的 ICollection<T>。 (继承自 IDictionary<Object, Object>。)

页首

方法

  名称 说明
公共方法 Add(T) 将某项添加到 ICollection<T> 中。 (继承自 ICollection<KeyValuePair<Object, Object>>。)
公共方法 Add(TKey, TValue) IDictionary<TKey, TValue> 中添加一个带有所提供的键和值的元素。 (继承自 IDictionary<Object, Object>。)
公共方法 Add<T>(T) 使用键的对象的 Type 将对象添加到该字典。
公共方法 Clear ICollection<T> 中移除所有项。 (继承自 ICollection<KeyValuePair<Object, Object>>。)
公共方法 Contains 确定 ICollection<T> 是否包含特定值。 (继承自 ICollection<KeyValuePair<Object, Object>>。)
公共方法 ContainsKey 确定 IDictionary<TKey, TValue> 是否包含具有指定键的元素。 (继承自 IDictionary<Object, Object>。)
公共方法 CopyTo 从特定的 Array 索引处开始,将 ICollection<T> 的元素复制到一个 Array 中。 (继承自 ICollection<KeyValuePair<Object, Object>>。)
公共方法 GetEnumerator() 返回一个循环访问集合的枚举数。 (继承自 IEnumerable<KeyValuePair<Object, Object>>。)
公共方法 GetEnumerator() 返回一个循环访问集合的枚举数。 (继承自 IEnumerable。)
公共方法 GetValue<T>() 获取具有指定引用类型的对象。
公共方法 GetValue<T>(Object) 获取具有指定引用类型并与指定键相关联的对象。
公共方法 Remove(TKey) IDictionary<TKey, TValue> 中移除带有指定键的元素。 (继承自 IDictionary<Object, Object>。)
公共方法 Remove(T) ICollection<T> 中移除特定对象的第一个匹配项。 (继承自 ICollection<KeyValuePair<Object, Object>>。)
公共方法 Remove<T>() 从该字典中移除具有指定 Type 的对象。
公共方法 TryGetValue(TKey, TValue%) 获取与指定的键相关联的值。 (继承自 IDictionary<Object, Object>。)
公共方法 TryGetValue<T>(T%) 获取具有指定类型的对象。
公共方法 TryGetValue<T>(Object, T%) 获取具有指定类型并与指定键相关联的对象。

页首

备注

您可以将自定义数据添加到 SharePoint 工具对象模型中实现 IAnnotatedObject 接口的类型实例。 这些类型具有一个可返回 IAnnotationDictionary 对象的 Annotations 属性。 有关更多信息,请参见 将自定义数据与 SharePoint 工具扩展相关联

请参见

参考

Microsoft.VisualStudio.SharePoint 命名空间