GraphPathSerializationDictionary.Item 属性

获取或设置具有指定键的元素。

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

语法

声明
Public Default Property Item ( _
    key As String _
) As String
public string this[
    string key
] { get; set; }
public:
virtual property String^ default[String^ key] {
    String^ get (String^ key) sealed;
    void set (String^ key, String^ value) sealed;
}
abstract Item : string with get, set
override Item : string with get, set
JScript 不支持索引属性。

参数

  • key
    类型:System.String
    要获取或设置的元素的键。

属性值

类型:System.String
具有指定键的元素。

实现

IDictionary<TKey, TValue>.Item

异常

异常 条件
ArgumentNullException

key 为 null。

KeyNotFoundException

检索了属性但没有找到密钥。

NotSupportedException

属性被设置且 System.Collections.Generic.IDictionary 是只读

.NET Framework 安全性

请参见

参考

GraphPathSerializationDictionary 类

Microsoft.VisualStudio.GraphModel 命名空间